in reply to Why does NOT operator on match operator on string concatenation require two pairs of parens?

$ perl -MO=Deparse -e'if (not $label.$inst =~ /\blea\b/i) {}' unless ($label . $inst =~ /\blea\b/i) { (); } -e syntax OK
$ perl -MO=Deparse -e'if (not ($label.$inst) =~ /\blea\b/i) {}' if (!($label . $inst) =~ /\blea\b/i) { (); } -e syntax OK
Naked blocks are fun! -- Randal L. Schwartz, Perl hacker
  • Comment on Re: Why does NOT operator on match operator on string concatenation require two pairs of parens?
  • Select or Download Code