[RFC] Pipe Assignment Operator
| From: | Caleb White | Date: | Fri, 10 Jul 2026 04:45:32 +0000 |
| Subject: | [RFC] Pipe Assignment Operator | ||
| Groups: | php.internals | ||
| Request: | Send a blank email to internals+get-131849@lists.php.net to get a copy of this message | ||
Hi internals,
I'd like to open discussion on my (first!) RFC for the pipe assignment operator (|>=):
https://wiki.php.net/rfc/pipe_assignment_operator
It adds a compound assignment form of the pipe operator, so that
$x |>= callable is shorthand for $x = $x |> callable, with
support for chaining. Implementation with tests is at:
https://github.com/php/php-src/pull/22633
Looking forward to your feedback.
Thanks!
Caleb