MiniMizer has asked for the wisdom of the Perl Monks concerning the following question:
Hi,
I'm trying to find a way to send arguments to a subroutine which I'm referencing to via SIG{"ALRM"}.
i.e.
SIG{"ALRM"}=\&Timeout($error);
I have a single subroutine that handled the timeouts, but I want it to get a different arguments based on the bit of code where the timeout occured, for instance.
Is this something that can be done? I haven't been able to get it to work using the above syntax.
|
---|
Replies are listed 'Best First'. | |
---|---|
Re: Passing arguments to a function reference
by choroba (Cardinal) on Jul 21, 2013 at 20:06 UTC | |
Re: Passing arguments to a function reference
by BrowserUk (Patriarch) on Jul 21, 2013 at 20:13 UTC | |
Re: Passing arguments to a function reference
by rjt (Curate) on Jul 21, 2013 at 22:04 UTC | |
by DrHyde (Prior) on Jul 22, 2013 at 11:01 UTC | |
by MiniMizer (Initiate) on Jul 22, 2013 at 14:49 UTC |
Back to
Seekers of Perl Wisdom