note 126000 added to language.types.null
| From: | hydrogen at live dot in | Date: | Sat, 10 Apr 2021 03:39:51 +0000 |
| Subject: | note 126000 added to language.types.null | ||
| Groups: | php.notes | ||
| Request: | Send a blank email to php-notes+get-216271@lists.php.net to get a copy of this message | ||
I would like to add for clarification that:
$x=NULL;
--$x;
// $x is still NULL.
// Decrementing NULL, using Decrement Operator, gives NULL.
$x-=1;
// $x is now int(-1).
// This actually decrements value by 1.
On the other hand, Incrementation works simply as expected.
Hope this helps :)
----
Server IP: 45.112.84.4
Probable Submitter: 45.112.85.242 (proxied: 223.223.129.136)
----
Manual Page -- https://php.net/manual/en/language.types.null.php
Edit -- https://main.php.net/note/edit/126000
Del: integrated -- https://main.php.net/note/delete/126000/integrated
Del: useless -- https://main.php.net/note/delete/126000/useless
Del: bad code -- https://main.php.net/note/delete/126000/bad+code
Del: spam -- https://main.php.net/note/delete/126000/spam
Del: non-english -- https://main.php.net/note/delete/126000/non-english
Del: in docs -- https://main.php.net/note/delete/126000/in+docs
Del: other reasons-- https://main.php.net/note/delete/126000
Reject -- https://main.php.net/note/reject/126000
Search -- https://main.php.net/manage/user-notes.php