develooper Front page | perl.perl6.language | Postings from May 2005

Re: ^method ?

Thread Previous | Thread Next
Larry Wall
May 13, 2005 21:25
Re: ^method ?
Message ID:
On Sat, May 14, 2005 at 11:41:23AM +0800, Autrijus Tang wrote:
: Juerd informed me today that .method should still means $_.method.
: However, for the OO modules we're writing, there still needs to be a way
: to invoke methods on the current invocant, when the invocant name has
: been omitted from the method() declaration.
: Currently Pugs has:
:     $?SELF.method
:     ^method
: Is any of the two forms considered canonical?  Or is there some other
: alternatives?

At the moment $?SELF is the only canonical form, though the invocant
is also in $_ at least until it's rebound.  Any other forms will
probably involve a pragma or macro, since there is no consensus on
a shortcut.


Thread Previous | Thread Next Perl Programming lists via nntp and http.
Comments to Ask Bjørn Hansen at | Group listing | About