# New Ticket Created by Daniel Șuteu # Please include the string: [perl #125286] # in the subject line of all future correspondence about this issue. # <URL: https://rt.perl.org/Ticket/Display.html?id=125286 > Let's assume the following code: #===BEGIN===# use 5.010; use strict; use warnings; sub a { return "foo"; } sub b { my ($x, $y) = @_; say $x; # $x is "foo" say $y; # $y is undefined } b(a() // return(), "bar"); # this fails b(a() // return, "bar"); # this works b(a() // (return()), "bar"); # this works #===END===# In the first call, the second parameter ($y) becomes undefined. This is triggered by the return keyword used with parentheses. In the second call, after removing the parentheses, it seems to work correctly. Also, wrapping the return inside parentheses seems to work too. As far as I tested, the issue can be reproduced only with the "return" keyword. It's reproducible with the following versions of Perl (and possible others): 5.14.4, 5.20.2, perl-5.22.0-RC2 Output: #===BEGIN===# foo Use of uninitialized value $y in say at x.pl line 12. foo bar foo bar #===END===#Thread Next