On 17/05/2016 11:55, Jesse Schalken wrote:
$id = $id
    |> StringList::decode($$)
    |> array_replace($$, $replace)
    |> StringList::encode($$);

To reiterate my comments from earlier in the thread, I think the "$id = $id" looks really weird here, and spoils the step-by-step layout - and, in this case, the symmetry.

I would like to be able to write it as:

$id
    |> StringList::decode($$)
    |> array_replace($$, $replace)
    |> StringList::encode($$)
    |>= $id;

Or just:

$id
    |> StringList::decode($$)
    |> array_replace($$, $replace)
    |> StringList::encode($$)
    |> $id;


Sara, what do you think of this tweak, and my subsequent suggestion that the pipe should only be usable as a *statement*, not an *expression*?

Regards,
--
Rowan Collins
[IMSoP]

--
PHP Internals - PHP Runtime Development Mailing List
To unsubscribe, visit: http://www.php.net/unsub.php

Reply via email to