in reply to Re^3: Calling $function from $module
in thread Calling $function from $module

He saying you could have used

( $p.'::'.$s )->()

It's the alternate form of

&{ $p.'::'.$s }()

The following should be avoided since it inherits the parent's @_ rather than creating a new one:

&{ $p.'::'.$s }

I recommend against both of your solutions. The first (&{ $p.'::'.$s }) is wrong and the second (*{ $p.'::'.$s }->()) is weird.

Replies are listed 'Best First'.
Re^5: Calling $function from $module
by BrowserUk (Patriarch) on Aug 05, 2015 at 23:23 UTC

    You're wrong about what "he is saying": constants aren't variables.

    His 'suggestions' are meaningless: constants aren't variables.

    *{ $p.'::'.$s }->() ... is weird

    Hm. I thought you'd like that one, since I learnt it from you.


    Anyone got any experience of this phone's predecessor?

    With the rise and rise of 'Social' network sites: 'Computers are making people easier to use everyday'
    Examine what is said, not who speaks -- Silence betokens consent -- Love the truth but pardon error.
    "Science is about questioning the status quo. Questioning authority". I knew I was on the right track :)
    In the absence of evidence, opinion is indistinguishable from prejudice.
    I'm with torvalds on this Agile (and TDD) debunked I told'em LLVM was the way to go. But did they listen!