jfrm has asked for the wisdom of the Perl Monks concerning the following question:
Bald-headed Comrades,
I've read about checking that the number of arguments passed by a subroutine is correct, prototyping and how it shouldn't be necessary. Generally speaking I do check args passed within the code and so that seems right.
However, I regularly change the number of values returned by subroutines and I often seem to make mistakes with this - by overlooking an instance of the calling subroutine or overlooking a return statement. So I would like to find a way or a tool for checking all subroutines across all my PERL files to make sure that the number of values expected matches every instance of the return statement within each routine.
Any ideas? Thanks for any advice.
|
---|
Replies are listed 'Best First'. | |
---|---|
Re: Checking number of values returned
by BrowserUk (Patriarch) on Feb 08, 2015 at 14:39 UTC | |
by jfrm (Monk) on Feb 09, 2015 at 09:39 UTC | |
by BrowserUk (Patriarch) on Feb 09, 2015 at 13:09 UTC | |
Re: Checking number of values returned
by LanX (Saint) on Feb 08, 2015 at 16:24 UTC | |
Re: Checking number of values returned
by clueless newbie (Curate) on Feb 08, 2015 at 13:24 UTC | |
by jfrm (Monk) on Feb 09, 2015 at 09:55 UTC | |
Re: Checking number of values returned
by Anonymous Monk on Feb 08, 2015 at 13:08 UTC | |
by LanX (Saint) on Feb 08, 2015 at 18:44 UTC | |
Re: Checking number of values returned
by Anonymous Monk on Feb 09, 2015 at 11:21 UTC |