Re: Thank you to JetBrains (PHP 8 Announcement page)
| From: | Benjamin Morel | Date: | Fri, 27 Nov 2020 16:42:12 +0000 |
| Subject: | Re: Thank you to JetBrains (PHP 8 Announcement page) | ||
| References: | 1 | Groups: | php.internals |
| Request: | Send a blank email to internals+get-112308@lists.php.net to get a copy of this message | ||
I really like this page as well! It will definitely help improve PHP's
reputation and adoption.
I'd like to suggest a couple improvements, though:
1/ Match expression:
The new match is similar to switch and has the following features:
> (...)
> *+ Match throws an UnhandledMatchError if no match is found*
2/ Nullsafe operator:
Instead of null check conditions, you can now use a chain of calls with the
> new nullsafe operator.
> *- When the evaluation of one element in the chain fails*, the execution
> of the entire chain aborts and the entire chain evaluates to null.
> *+ When one element in the chain evaluates to null*, the execution of the
> entire chain aborts and the entire chain evaluates to null.
IMO, "fails" could imply that an unknown property, or a property that
evaluates to a non-object is acceptable.
Sorry if these suggestions come a bit late, now that translations have
landed.
— Benjamin
On Fri, 27 Nov 2020 at 16:40, Sara Golemon <pollita@php.net> wrote:
> I've been receiving fantastic feedback on the PHP 8.0 Announcement landing
> page ( https://www.php.net/releases/8.0 ), and I just wanted to
> extend a
> big Thank You to all the folks at JetBrains for making this suggestion and
> putting forth the work on the initial four translations (en, pt_BR, de, and
> ru). This has helped spread the excitement around this release, and I hope
> we continue the tradition next year!
>
> -Sara
>
> P.S. - It's especially encouraging that our community stepped up
> immediately to provide two more translations (fr and zh; plus I happen to
> know my wife is working on Spanish as I type this).
>