in reply to passing and processing code references
You could take a string and do an eval on it. That will be slow, can lead to an unmaintainable design, etc, but you can.
However I would strongly prefer using an anonymous function and I am curious why you do not. Remember, focus on what it is that you want to accomplish, not how you want to accomplish it. So make it be an anonymous function, and either use local on $file, or pass it as an argument to the function.
Personally I would pass it as an argument. If I want flexibility, then pass a hash of arguments...
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
RE: Re (tilly) 1: passing and processing code references
by princepawn (Parson) on Oct 11, 2000 at 17:06 UTC | |
by tilly (Archbishop) on Oct 11, 2000 at 17:53 UTC |