Re: [RFC] Keep type of reference params
| From: | Ben Ramsey | Date: | Mon, 04 May 2020 14:49:14 +0000 |
| Subject: | Re: [RFC] Keep type of reference params | ||
| References: | 1 2 | Groups: | php.internals |
| Request: | Send a blank email to internals+get-109989@lists.php.net to get a copy of this message | ||
> On May 4, 2020, at 08:01, Matthew Brown <matthewmatthew@gmail.com> wrote:
>
> This would break quite a lot of existing code, though PHP could add an
> explicit keyword like "inout" that catches this behaviour (see example in
> Hack: https://docs.hhvm.com/hack/functions/inout-parameters).
>
> Today these issues can also be caught with static analysis:
> https://psalm.dev/r/1f670956ab
I think I’d be supportive of adding
Attachment: [application/pgp-signature] Message signed with OpenPGP signature.asc
inout parameters in addition to existing support
for references.
Cheers,
Ben
Attachment: [application/pgp-signature] Message signed with OpenPGP signature.asc