In my mind

perl -le 'print join "\n", map { "[" . 0 x $_ . "]" } -1 .. 1'

and

pugs -e 'say join "\n", map { "[{ 0 x $_}]" }, -1 .. 1'

should both print
[]
[]
[0]

But the Pugs code throws
pugs: List.genericTake: negative argument

Is this Pugs specific behavior or has the the x operator changed with
respect to negative values?

from perldoc perlop
      If the right operand is zero or negative, it returns an empty
string . . .

Reply via email to