Re: Re: Zero-fill right shift.
| From: | Ben | Date: | Tue, 03 Feb 2015 13:28:05 +0000 |
| Subject: | Re: Re: Zero-fill right shift. | ||
| Groups: | php.internals | ||
| Request: | Send a blank email to internals+get-81709@lists.php.net to get a copy of this message | ||
>>> is called a logical right shift (in contrast to the arithmetic right shift >>).
>>> This would be a good addition.
$op1 >>> $op2 is equivalent to ($op1 >> $op2) & (PHP_INT_MAX >> $op2 - 1)
========== Original ==========
From: Leigh <leight@gmail.com>
To: internals@lists.php.net
Date: Tue, 03 Feb 2015 14:24:07 +0100
Subject: [PHP-DEV] Re: Zero-fill right shift.
> This will introduce a T_SHRZF token and corresponding opcode. Targeting PHP 7.
That should have been T_SRZF, and I suppose I would also have to add
">>>=" (T_SRZF_EQUAL) which looks nasty, but should be included for
completeness.