Hmm.

Larry Wall wrote: [to [EMAIL PROTECTED]]
> This is much like a method:
> 
>     my Cat &chases (Dog $spot) :<lvalue method> = { ... };
> 
> In either case, Cat is the type of the return value, and really has
> little to do with the implementation of the function (or hash) itself.
> $spot.chases is a Dog method, not a Cat method.  In the same way,
> %chases is a Catalog method, not a Cat method.


This wouldn't mean that anyone is thinking of getting us object
dot-syntax, now
would it? After giving it a thought, it seems that it can _mostly_ be
disambiguated from the concatenation operator. Whatever mostly means.

# given
$cat = bless [], 'Cat';
$purr = 'fish';

# we could have
$cat.purr();   # easy: $cat->purr()
$cat.$purr;    # easy: "Catfish"
Cat.purr();    # easy: Cat->purr()
Cat.$purr();   # hmmm: Cat() . "fish" (or Cat->$purr?)

# and
$cat = 'Cat';
$cat.purr;     # Cat->purr() (or "Cat" . purr()?)


If $cat has method purr() and one has defined function purr(), all of
the above become ambiguous... So? A cut with the disambiguation-razor
would fix that, no?


This would make my life complete, especially if we get to do stuctish
things as well.

It seems that John Porter said something about this back in September
(http://ml.perl.org/archive.develooper.com/perl6-language_perl.org/msg04864.html),
and it has come up some ten times, but never had any final discussion.
There may be a good reason for that :(



Thanks for your<:plural> attention && now back to lurking,

d.
-- 
davíð helgason                        [EMAIL PROTECTED]

Reply via email to