in reply to "not grep iterator" error
OUTPUT:perl -we "use strict; sub subby(&\@\@){print qq|in subby..@{$_[2]};\n| +}; my @x=subby sub{print qq|calling...|},my @c, @{[ grep {/\d/} 0..6] +}"
Basically - encapsulate the "grep" result into something that looks like an array (Make an arrayref and dereference it).
But, like Fletch said .. do the right thing, and declare it properly.
Potentia vobiscum ! (Si hoc legere scis nimium eruditionis habes)
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re^2: "not grep iterator" error
by toddfreed (Novice) on Sep 09, 2009 at 21:54 UTC | |
by ikegami (Patriarch) on Sep 09, 2009 at 22:11 UTC |