in reply to Re: goto &sub and local question
in thread goto &sub and local question
That's what I thought too, but as it was pointed out above, it is not correct, and if I had read the docs instead of trusting my memory, I wouldn't have posted this question. After all, the docs clearly say that localization is undone.
Whether this is a nice concept or not, is another question. It seems that when you want to pass control to another sub without creating a new stack frame, the only possibility to pass additional information accross the goto &... boundary is by using global (non-localized) variables.
OTOH, I think the occasions to use such a construct are so rare that it's not so bad to use a non-localized global variable for this task. </c>
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re^3: goto &sub and local question
by almut (Canon) on Nov 24, 2008 at 09:41 UTC | |
by rovf (Priest) on Nov 24, 2008 at 12:37 UTC | |
|
Re^3: goto &sub and local question
by Bloodnok (Vicar) on Nov 24, 2008 at 09:46 UTC | |
|
Re^3: goto &sub and local question
by SuicideJunkie (Vicar) on Nov 24, 2008 at 17:39 UTC | |
by TGI (Parson) on Nov 25, 2008 at 02:26 UTC | |
by ikegami (Patriarch) on Nov 25, 2008 at 03:18 UTC | |
by TGI (Parson) on Nov 25, 2008 at 21:26 UTC | |
by ikegami (Patriarch) on Nov 26, 2008 at 00:18 UTC |