I've just spotted another issue with list assignment in list context. Does anyone think the third case below is a bug? I think it should output "1:u" like the second case: sub f { print join(':', map $_ // "u", @_), "\n"; } f(($a,$b) = () ); # prints "u:u" f(($a,$b) = (1)); # prints "1:u" f(($a,$b, %h) = (1)); # prints "1" on the principle that the return value of a list assignment is its LHS; i.e. that @a = ((X) = (Y)) should be equivalent to (X) = (Y); @a = (X), where (X) is a list of lvals, like ($a, undef, %h) -- The warp engines start playing up a bit, but seem to sort themselves out after a while without any intervention from boy genius Wesley Crusher. -- Things That Never Happen in "Star Trek" #17Thread Previous | Thread Next