Graham Barr wrote:

> I would say it is not always redundant to specify the type on both
> sides
> 
>     my Dog $dog = Greyhound.new('black');

Sure. But it's the redundant case we were trying to simplify.


>>And, furthermore, that you could easily define special semantics
>>for void-context constructor calls via undef'd but typed variables,
>>so that you could just write:
>>
>>      (my Date $date).new('June 25, 2002');
> 
> So that would be creating special case syntax for
> a specific case of a general issue.

No. It would be creating special case syntax for
a *special* case of a general issue. ;-)

But I must say I now like Adam's

        my Date $date .= new('June 25, 2002');

much more than my own proposal.

Damian


Reply via email to