in reply to ?: conditional operators appear to fail

Parenthesizing the truth value used with ?: is a good idea - usually. Got myself into a pickle the other day, though.
warn ($msg =~ m/\n$/) ? $msg : ($msg . "\n");
didn't work quite as expected. After a bit'o head scratching about no results and complaints about "void context", I remembered the nastiness pointed out about 'print' and others, and realized the left paren was confusing the parser into thinking "warn()".

In _this_ case, removing the parens worked better...

warn $msg =~ m/\n$/ ? $msg : ($msg . "\n");