Grupos de Google ya no admite publicaciones ni suscripciones nuevas de Usenet. El contenido anterior sigue visible.

[perl #40490] Flat/Slurpy Named Parameter Passing Errors

3 vistas
Ir al primer mensaje no leído

Chromatic

no leída,
9 oct. 2006, 6:38:08 p. m.9/10/06
para bugs-bi...@rt.perl.org
# New Ticket Created by chromatic
# Please include the string: [perl #40490]
# in the subject line of all future correspondence about this issue.
# <URL: http://rt.perl.org/rt3/Ticket/Display.html?id=40490 >


Given this code:

.sub 'main' :main
.local pmc args
args = new .Hash
args['foo'] = 1
args['bar'] = 2

bar_only( args :flat :named )
.end

.sub 'bar_only'
.param string bar :named( 'bar' )
.param pmc args :named :slurpy

print "Have bar: "
print bar
print "\n"
.end

I expect bar to be '2' in bar_only(). Somehow the value seems to get lost.
I'll add this test to t/op/calling.t when I get the ticket number.

-- c

0 mensajes nuevos