in reply to Re^3: Dereferencing code refs with & vs. ->()
in thread Dereferencing code refs with & vs. ->()

He knows they have nothing to do with dereferencing. He was contradicting the following completely false statement (which had nothing to do with dereferencing):
About the only place you'd need the ampersand version is if you're trying to get the current scope's @_ passed a la &somesub;. But that's really rare.
  • Comment on Re^4: Dereferencing code refs with & vs. ->()

Replies are listed 'Best First'.
Re^5: Dereferencing code refs with & vs. ->()
by Fletch (Bishop) on Sep 23, 2005 at 21:35 UTC

    However the OP was bout dereferencing and given that context it is about the only place you have to use an ampersand. Taking a reference to a named sub has nothing to do with using & versus -> in dereferencing and calling a coderef. The point about goto &$coderef is correct (and that would be one of the exceptions that I was alluding to by qualifying with about), but as the AM points out prototype checking doesn't apply to coderefs so that "counterexample" is also not really relevant. Given the original context the statement is not "completely false".