in reply to Re: Random Tips on Parse::RecDescent
in thread Random Tips on Parse::RecDescent
Ok, I'll bite...
So my question is why?#!/perl/bin/perl # # coderefs.pl -- Yes you can use strict... use strict; use warnings; use diagnostics; for (qw(foo bar)) { ($main::{$_} or sub { print "No such sub: $_\n" })->(); } $_ = 'baz'; $main::{$_}(); # works! but, &{$_}(); # doesn't... sub foo { print "Yes, I'm here.\n"; } sub baz { print "I'm here as well.\n"; } __END__
–hsm
"Never try to teach a pig to sing…it wastes your time and it annoys the pig."
|
---|
Replies are listed 'Best First'. | |
---|---|
Re^3: Random Tips on Parse::RecDescent
by Aristotle (Chancellor) on Jul 13, 2002 at 02:30 UTC | |
by hsmyers (Canon) on Jul 13, 2002 at 16:10 UTC |
In Section
Meditations