in reply to Re^3: If you believe in Lists in Scalar Context, Clap your Hands
in thread If you believe in Lists in Scalar Context, Clap your Hands
perhaps with the exception of :lvalue subs, haven't tried those
lvalue subs are called in scalar context, so they can't return a list.
use strict; use warnings; my ($i,$j); sub f :lvalue { ($i,$j) } f() = (4,5); print("$i,$j\n");
Useless use of a constant in void context at script.pl line 5. Use of uninitialized value in concatenation (.) or string at script.pl + line 6. ,5
|
---|
Replies are listed 'Best First'. | |
---|---|
Re^5: If you believe in Lists in Scalar Context, Clap your Hands
by ysth (Canon) on Oct 28, 2008 at 04:51 UTC | |
by ikegami (Patriarch) on Oct 28, 2008 at 10:21 UTC | |
by JavaFan (Canon) on Oct 28, 2008 at 11:05 UTC | |
by ysth (Canon) on Oct 28, 2008 at 18:34 UTC |