in reply to Re^3: how to declare a local *subname=sub{}?
in thread how to declare a local *subname=sub{}?
The call to "stuff" is within the scope of the "local *asub", which has a value assigned to "asub" that is also within the same scope as "sub stuff".
i.e. the "undef" value preserved outside of the scope of the "local" ends past "sub stuff".
That's why it is a curiosity. I couldn't see (and still don't) why adding the "local" statement (who's scope includes "sub stuff") should make a difference.
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re^5: how to declare a local *subname=sub{}?
by LanX (Saint) on Oct 31, 2016 at 12:35 UTC |