I have define a custom module which contains 2 utility function to return matched/unmatched boolean.
Additionally there is a function which returns the result using these util functions.
So,if i need to filter files from a directory which are not directory themselves,i need to call
my @collfiles=modules::unixop::accumulatecoll($func,\@files,$filter) ;
where $func=\&modules::unixop::filterirrelevant;
@files contains the output of the dir command.
and $filter=DIR.
This will use the utility function filterirrelevant to return the non-dir files as a collection.
But i get an error as:
Too many arguments for modules::unixop::accumulatecoll at perlexecs\xmlfeed.pl li
ne 22, near "$filter) "
What am i doing wrong?
If i shift this function within the same unit,(rather than invoing from a module) I do not get this compilation error.
Additionally there is a function which returns the result using these util functions.
So,if i need to filter files from a directory which are not directory themselves,i need to call
my @collfiles=modules::unixop::accumulatecoll($func,\@files,$filter) ;
where $func=\&modules::unixop::filterirrelevant;
@files contains the output of the dir command.
and $filter=DIR.
This will use the utility function filterirrelevant to return the non-dir files as a collection.
But i get an error as:
Too many arguments for modules::unixop::accumulatecoll at perlexecs\xmlfeed.pl li
ne 22, near "$filter) "
What am i doing wrong?
If i shift this function within the same unit,(rather than invoing from a module) I do not get this compilation error.