in reply to Re^5: why doesn't "my ($a,$b)" return a list?
in thread why doesn't "my ($a,$b)" return a list?
> I don't see how you could pass something that could be flattened.
hmm my (@a,$b,%h) behaves like a function with infinte prototype
sub my (\[@$%];\[@$%]\[@$%]\[@$%]\[@$%]\[@$%]\[@$%]\[@$%]\[@$%]\[@$%] and so on )
which avoids flattening.
OTOH the lvalue character can't be simulated for more than one value.
> > Well, my behaves different in several aspect to other buildins.
> A lot of builtins have unique parsing rules. (print, map, sort, system, our, ...) And?
The "And" is: If parsing rules are different, so why not the behaviour in scalar context, too?
Cheers Rolf
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re^7: why doesn't "my ($a,$b)" return a list?
by ikegami (Patriarch) on Aug 19, 2010 at 20:26 UTC | |
by LanX (Saint) on Aug 19, 2010 at 21:02 UTC | |
by ikegami (Patriarch) on Aug 19, 2010 at 21:18 UTC | |
by LanX (Saint) on Aug 19, 2010 at 21:30 UTC | |
by ikegami (Patriarch) on Aug 19, 2010 at 23:05 UTC | |
|