at least seems to work… This is common in Lisp and other 'functional' languages, and Pascal if memory serves, but I can't say as to how I've ever felt the need in other languages. Dosen't mean that there isn't a need, just not one I've ever run into.#!/perl/bin/perl # # -- use strict; use warnings; use diagnostics; my $test = "hello world\n"; my $stub = sub {$test = "goodbye world\n"}; print $test; &$stub; print $test;
hsm
In reply to Re: subroutines and namespace
by hsmyers
in thread subroutines and namespace
by George_Sherston
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |