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 considered bugs, but require breaking compatibility:

1) Bring the behaviour of decrementing null in line with subtracting 1 (and with the equivalent increment operator) 2) Bring the behaviour of incrementing or decrementing true and false in line with adding or subtracting 1 3) Throw the same error when incrementing or decrementing an array as when adding or subtracting 1

I believe the behaviour of strings, objects, and resources, each raise sufficient extra questions that they should be left to future RFCs where we can focus on each in more detail.

Please read the RFC for more detail on what is and isn't proposed.

Regards,

--
Rowan Tommins (né Collins)
[IMSoP]

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

Reply via email to