Ben Tilly wrote: > Tom Metro wrote: >> sub { >> local *__ANON__ = "subname"; # name the anon sub > > Rather than a semi-documented trick, I'd recommend the clearly > documented Sub::Name module for this.
Agreed. I just ran across Sub::Name yesterday when I was trying to dig up more info on the syntax for using __ANON__. I've since updated the code to use Sub::Name. It really is functionality that should be built-in to the sub statement. >> If it is used as a glob...it works, but >> produces output prefixed with "*"... > > The * prefix just indicates that > it is being interpreted as some other glob, but if you look at the > output the glob it appears as should be what you were trying to name > it. I'm not following. It feels like either the "*" should be consumed by the tokenizer as part of the variable, or treated as extraneous junk and either passed to the statement/function, or trigger a syntax error. -Tom -- Tom Metro Venture Logic, Newton, MA, USA "Enterprise solutions through open source." Professional Profile: http://tmetro.venturelogic.com/ _______________________________________________ Boston-pm mailing list Boston-pm@mail.pm.org http://mail.pm.org/mailman/listinfo/boston-pm