Re: [perl #56638] Zero-argument return doesn't work

2008-07-07 Thread Larry Wall
On Mon, Jul 07, 2008 at 10:09:37PM -0700, Larry Wall wrote: : So : : $x = nothing(); # = [] : @x = nothing(); # = () : %x = nothing(); # = () : if nothing() {...}# always false : $x = nothing()[0] # "Subscript out of range"

Re: [perl #56638] Zero-argument return doesn't work

2008-07-07 Thread Larry Wall
On Mon, Jul 07, 2008 at 11:43:56PM -0500, Patrick R. Michaud wrote: : On Mon, Jul 07, 2008 at 08:18:36PM -0700, Larry Wall wrote: : > On Mon, Jul 07, 2008 at 07:16:05PM -0700, Patrick R. Michaud via RT wrote: : > : Note however that TimToady on #perl6 speculated [1] that an empty return : > : shoul

Re: [perl #56638] Zero-argument return doesn't work

2008-07-07 Thread Patrick R. Michaud
On Mon, Jul 07, 2008 at 08:18:36PM -0700, Larry Wall wrote: > On Mon, Jul 07, 2008 at 07:16:05PM -0700, Patrick R. Michaud via RT wrote: > : Note however that TimToady on #perl6 speculated [1] that an empty return > : should return the Object prototype. I'm not sure the answer was > : resolved com

Re: [perl #56638] Zero-argument return doesn't work

2008-07-07 Thread Larry Wall
On Mon, Jul 07, 2008 at 07:16:05PM -0700, Patrick R. Michaud via RT wrote: : Note however that TimToady on #perl6 speculated [1] that an empty return : should return the Object prototype. I'm not sure the answer was : resolved completely in that thread, however, so we'll go with returning : 'undef

[perl #56638] Zero-argument return doesn't work

2008-07-07 Thread Patrick R. Michaud via RT
Applied (with one minor change) in r29143, thanks! Note however that TimToady on #perl6 speculated [1] that an empty return should return the Object prototype. I'm not sure the answer was resolved completely in that thread, however, so we'll go with returning 'undef' for now and wait for a more d

[perl #56638] Zero-argument return doesn't work

2008-07-06 Thread Carl Mäsak
# New Ticket Created by "Carl Mäsak" # Please include the string: [perl #56638] # in the subject line of all future correspondence about this issue. # http://rt.perl.org/rt3/Ticket/Display.html?id=56638 > The `return` built-in doesn't take zero arguments, like it can in Perl 5. The attached p