sub foo { $list = $foo_cache{join ',', @_} ||= [ do { ... rest of sub goes here }]; want_array ? @$list : $list; }
In reply to Re: inline caching a list-generating sub
by Roger
in thread inline caching a list-generating sub
by ysth
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |