On Mon, 2 Mar 2020 at 14:46, Marco Pivetta wrote:
>
> The code above is NOT going to pass a code review.
>
It may not pass a code review *from you*, but I don't think your high
standards are a good benchmark for the way PHP is used throughout the world.
Let's put it this way: if my RFC passes
Hey Rowan,
On Mon, Mar 2, 2020 at 3:39 PM Rowan Tommins
wrote:
> Hi Marco,
>
> On Mon, 2 Mar 2020 at 14:00, Marco Pivetta wrote:
>
> >
> > Overall against the RFC: `++` and `--` (prefix and suffix) are supposed
> to
> > be used with numeric values, not with other types, as that makes
> everythi
Am 02.03.2020 um 15:00 schrieb Marco Pivetta :
> Overall against the RFC: `++` and `--` (prefix and suffix) are supposed to
> be used with numeric values, not with other types, as that makes everything
> only more confusing.
>
> Code written (intentionally) to use `++` and `--` against non-numeric
Hi Marco,
On Mon, 2 Mar 2020 at 14:00, Marco Pivetta wrote:
>
> Overall against the RFC: `++` and `--` (prefix and suffix) are supposed to
> be used with numeric values, not with other types, as that makes everything
> only more confusing.
>
While I'm generally sympathetic to that principle, i
On 02/03/2020 14:08, Rowan Tommins wrote:
The problem with this kind of behaviour change is that there's no way
for PHP to know whether a particular piece of code has been changed to
expect the new behaviour or not
Lump it in with editions maybe?
--
PHP Internals - PHP Runtime Development Mai
Hi Alexandru,
On 2 March 2020 09:22:57 GMT+00:00, "Alexandru Pătrănescu"
wrote:
>For point 1 and 2, both the old and new behavior is silent. Can we
>think of
>a safer way to migrate?
That's a very good question, and one I don't have a particularly good answer to.
The problem with this kind of
Hey Rowan,
Overall against the RFC: `++` and `--` (prefix and suffix) are supposed to
be used with numeric values, not with other types, as that makes everything
only more confusing.
Code written (intentionally) to use `++` and `--` against non-numeric
values should **NOT** pass a code review, an
Hi Rowan,
Thank you for the effort, very good unification of behavior across
increment and decrement operations.
I would say that all 3 points are most probably code issues and potential
bugs.
I agree with all of them.
For point 3, the new behavior is an error. The problem will be caught
earlier
Hi all,
Following my thread a couple of weeks ago, I would like to put forward
an RFC to fix some inconsistencies with the behaviour of the ++ and --
operators:
https://wiki.php.net/rfc/increment_decrement_fixes
Note that this RFC focusses on three specific cases which I think could
be cons