Re: [PHP-DEV] [RFC] Integer Semantics

[email protected] (Dmitry Stogov)
Newsgroups php.internals
Message-ID <CA+9eiLspLBX6F7s9u+77HOuPLFbqOSHnfkvChAgzEA0B3TnzxQ@mail.gmail.com>
1) INF conversion to zero seems wrong. May be +INF should be converted to
MAX_LONG and -INF to MIN_LONG?

2) Negative shifts would be useful, as Sara mentioned.

3) a bit unrelated, but it also may make sense to introduce a logical right
shift operator (>>> in Java)

the rest seems fine, patch looks OK.

Thanks. Dmitry.


On Wed, Aug 20, 2014 at 8:05 AM, Sara Golemon <[email protected]> wrote:

> On Tue, Aug 19, 2014 at 3:36 PM, Andrea Faulds <[email protected]> wrote:
> > https://wiki.php.net/rfc/integer_semantics
> >
> In a perfect world, I'd rather see "<< -X" be equivalent to ">> X",
> but since we do something very different currently, I think your
> approach of throw an error and ask questions later seems appropriate.
> The other ones all sound inarguable.
>
> +1
>
> -Sara
>
> --
> PHP Internals - PHP Runtime Development Mailing List
> To unsubscribe, visit: http://www.php.net/unsub.php
>
>
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.