Re: RFC 174 (v1) Parse C<func($obj, @args)> as C<func $obj (@args)>
[email protected] (Damian Conway) Thu, 31 Aug 2000 11:39:52 +1100 (EST)
| Newsgroups | perl.perl6.language.subs |
|---|---|
| Message-ID | <[email protected]> |
> yet even that is not sufficient for some cases, where
>
> Y::->X
>
> instead. Blech.
I find the Y()->X() vs Y::->X() confusion of Y->X() to be simply a bug
in the "precedence" of symbolic refs vs bareword classnames. I think
that people very rarely mean the former.
The current resolution of the ambiguity is even less consistent when you
consider that $hash{Y} is always resolved in favour of $hash{'Y'},
rather than $hash{Y()}
> But given that these *do* differ, it seems reasonable to require
> different things to have different syntaxes. I hate not knowing
> what's going on.
>
> But I will *not* relish typing
>
> STDERR->print("darn")
Nor I. That's why I'd advocate mandatory braces on indirect objects.
I'd rather:
print {STDERR} "darn"
any day.
Damian