Special_K has asked for the wisdom of the Perl Monks concerning the following question:
How can I pass a reference to an anonymous empty array to a subroutine? Here is how I can pass an anonymous empty array to a subroutine:
&foo(qw());
Now how can I do the same with a reference to an anonymous empty array? I tried this:
&foo(\qw());
but that didn't work.
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re: passing anonymous empty array reference to subroutine
by choroba (Cardinal) on Apr 02, 2015 at 17:05 UTC | |
|
Re: passing anonymous empty array reference to subroutine
by AnomalousMonk (Archbishop) on Apr 02, 2015 at 17:21 UTC | |
|
Re: passing anonymous empty array reference to subroutine
by vinoth.ree (Monsignor) on Apr 02, 2015 at 20:01 UTC | |
|
Re: passing anonymous empty array reference to subroutine
by Anonymous Monk on Apr 06, 2015 at 12:27 UTC |