The above avoids no strict 'refs', but it doesn't actually buy you anything.use 5.010; use strict; use warnings; sub foo { say "This is foo <@_>" } sub bar { say "This is bar <@_>" } sub call { my $sub = shift; goto &$sub; } $_ = "foo 123 foo bar bar 456"; while (/(\w+) (\w+)/g) { call $1, $2; } __END__ This is foo <123> This is foo <bar> This is bar <456>
Adapting it to your own templating system (which neither seems useful, working or fast to me) is left as an exercise to the reader.
P.S. I graduated from university long before you flunked college. (Not that anyone should care).
In reply to Re: Meet Slang!
by JavaFan
in thread Meet Slang!
by Logicus
For: | Use: | ||
& | & | ||
< | < | ||
> | > | ||
[ | [ | ||
] | ] |