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

Re: ./method <defunct>

Thread Previous | Thread Next
From:
Juerd
Date:
June 19, 2005 10:55
Subject:
Re: ./method <defunct>
Message ID:
20050619175520.GU7412@c4.convolution.nl
David Storrs skribis 2005-06-19 13:45 (-0400):
> Seriously.  Are default invocants really such a good idea? 

Yes, as long as the default is $_.

./method doesn't use a default invocant. It calls method on the current
invocant, which happens to be available as $?SELF: that doesn't mean it
defaults to $?SELF. The term "default" is inappropriate if there is no
way to specify anything else: $object./method is still invalid syntax.

> All that said, I still agree with John... './' does not look like  
> method call syntax to me.

That's good, because it's different from all other method syntax anyway,
because it does not have any left hand side -- not even implied.


Juerd
-- 
http://convolution.nl/maak_juerd_blij.html
http://convolution.nl/make_juerd_happy.html 
http://convolution.nl/gajigu_juerd_n.html

Thread Previous | Thread Next


nntp.perl.org: Perl Programming lists via nntp and http.
Comments to Ask Bjørn Hansen at ask@perl.org | Group listing | About