Re: [Vote] Pipe operator
| From: | Levi Morrison | Date: | Tue, 13 May 2025 18:41:18 +0000 |
| Subject: | Re: [Vote] Pipe operator | ||
| References: | 1 | Groups: | php.internals |
| Request: | Send a blank email to internals+get-127344@lists.php.net to get a copy of this message | ||
On Mon, May 12, 2025 at 8:00 PM Larry Garfield <larry@garfieldtech.com> wrote:
>
> I hereby open the vote on the Pipe operator RFC:
>
> https://wiki.php.net/rfc/pipe-operator-v3
>
> The vote will run until 26 May.
Hey, Larry, quick check:
> Supporting pass-by-ref parameters in simple cases is quite easy, and
> a naive implementation would support it. However, passing a value
> from a compound value (an object property or array element) by
> reference does not work, and throws an “Argument could not be passed
> by reference” error. In practice, it is easier to forbid pass-by-ref
> parameters in pipe than to allow them.
Is this a restriction that can be lifted in a future version? I agree
that it's unlikely to be useful, but if the
$temp = chain version
supports it, then so too I would expect a pipeline to be able to
handle it.