in reply to Re: Function name in a variable, can't recall the concept
in thread Function name in a variable, can't recall the concept
It's technically the dereference of a symbolic reference that's not allowed. However, there is a (documented) exception:
\&$sub_name
This means that while
$sub_name->()
isn't allowed,
(\&$sub_name)->()
is allowed.
($invocant->$method_name() is also allowed under strict.)
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re^3: Function name in a variable, can't recall the concept
by Eily (Monsignor) on Apr 03, 2019 at 08:18 UTC | |
|
Re^3: Function name in a variable, can't recall the concept
by LanX (Saint) on Apr 14, 2019 at 13:50 UTC | |
by ikegami (Patriarch) on Apr 15, 2019 at 00:54 UTC | |
by LanX (Saint) on Apr 15, 2019 at 11:25 UTC | |
by ikegami (Patriarch) on Apr 16, 2019 at 19:14 UTC |