note 45076 deleted from language.operators.increment by hholzgra
| From: | hholzgra@php.net | Date: | Thu, 02 Aug 2012 15:22:07 +0000 |
| Subject: | note 45076 deleted from language.operators.increment by hholzgra | ||
| References: | 1 | Groups: | php.notes |
| Request: | Send a blank email to php-notes+get-189852@lists.php.net to get a copy of this message | ||
Note Submitter: timo at frenay dot net
----
JMcCarthy AT CitiStreet DOT com:
As for your March 31 post, at least in PHP version 4.3 this no longer holds for 'D'. Your
point is still valid for 'e' or 'E' and worth noting.
Your comment from May 12 is simply not true, although it might be a bug in your specific version of
PHP but that would seem very strange.
<?php
$Align = array('a', 'b', 'c');
$i = 0;
echo $Align[$i++]; // Prints 'a', as expected
?>
It might be interesting to know that pre-/postincrement assumes a value of 0 for undefined
variables, but pre-/postdecrement does not:
<?php
echo var_dump(++$foo); // int(1)
echo var_dump(--$bar); // NULL!
?>