Hi,

> > Hi internals,
> >
> > I discussed the syntax for attributes further with Benjamin, Martin,
> > and several other internals developers off-list, and with their
> > feedback completed an RFC proposing to use the shorter `@@` syntax
> > instead of `<<>>` for attributes in PHP 8.
> >
> > https://wiki.php.net/rfc/shorter_attribute_syntax
> >
> > The goal is not to bikeshed over subjective syntax preferences,
> > but to address several concrete shortcomings related to verbosity,
> > nested attributes, confusion with generics and other tokens, and
> > dissimilarity to other common languages.
>
> Just a heads up that the two week minimum discussion period expires
> tomorrow, and I'm planning to open voting soon.
>
>
Hi! Thanks for the notification. I'll probably vote for the `@@` syntax for
three reasons:

- It feels similar with at least other 5 or 6 languages that choose `@` as
their attribute sigil;

- The lack of closing brackets make it less verbose, both on nesting and
non nesting cases;

- BC breaking the stacking of the error suppression operator as in
`@@@@some_call()`
actually makes some sense. AFAIK there was no reason to allow it, and maybe
it was just
an implementation oversight? So if the new proposal comes with this nice
"fix" attached,
at least it feels like a fix to me, it's two good changes on the same
package. If not I'd
propose to disallow `@@@...` combos myself separately if there is time to
do so.


> Best regards,
> Theodore
>
> --
> PHP Internals - PHP Runtime Development Mailing List
> To unsubscribe, visit: https://www.php.net/unsub.php
>
>
Thank you for your work.

Cheers,
Márcio

Reply via email to