This came up on Perlmonks earlier today. Code A works as you would expect.
A) push @{ /PAT/ ? \@match : \@nonmatch }, $_ foreach @words; Code B gives a strange error (you'd expect it not to work, but you might not be able to guess the error). B) push @{ /PAT/ ? @match : @nonmatch }, $_ foreach @words; Given that Code B generates an error, why does Code C work? C) push @{ $_ % 2 ? @odd : @even }, $_ foreach @ints; Is it a bug? Dave... -- .sig missing...