Hi Lester,

I didn't add restrictions specific to number representation in the draft 
ruleset yet, becausen while I think that's an important point, I didn't have 
time to study it in depth.

I know you're an expert on this as you continuously (rightly) raised the point.

So, can you elaborate on this and send me or, better, publish on the list the 
detailed set of changes you suggest, including 32 bit vs 64 bit concerns if 
they fit. Today, conversion restrictions are rather limited as floats which 
don't fit in int give 0, and int to float is considered as always possible. I 
mean that must be technically incorrect, while unnoticed in the vast majority 
of cases.

So can you write a consistent set of changes you would introduce ?

Thanks

François

> -----Message d'origine-----
> De : Lester Caine [mailto:les...@lsces.co.uk]
> Envoyé : jeudi 19 février 2015 11:24
> À : internals@lists.php.net
> Objet : Re: [PHP-DEV] Reviving scalar type hints
> 
> On 19/02/15 09:13, Zeev Suraski wrote:
> > Obviously, I think 'weak' campers have a lot to gain too - by making
> > sensible conversions work fine as expected, without having to resort to
> > explicit casts.
> > And everyone stands to gain from having just one mode, instead of two.
> > The coercive typing approach would require each camp to give up a bit of
> > their 'ideology', but it also gives both schools of thought *most* of what
> > they want, including the key tenets for each camp (rejecting non-sensible
> > conversions - always, allowing sensible ones - always).  I believe that's
> > what makes it a good compromise, a better one than the currently
> proposed
> > RFC.
> 
> Now that all made sense!
> 
> My only grey area is 'allowing sensible ones' where the size is an
> integral part of what is 'sensible' ... the one where conventional
> strict typing uses a type of the right size?
> 
> --
> Lester Caine - G8HFL
> -----------------------------
> Contact - http://lsces.co.uk/wiki/?page=contact
> L.S.Caine Electronic Services - http://lsces.co.uk
> EnquirySolve - http://enquirysolve.com/
> Model Engineers Digital Workshop - http://medw.co.uk
> Rainbow Digital Media - http://rainbowdigitalmedia.co.uk
> 
> --
> PHP Internals - PHP Runtime Development Mailing List
> To unsubscribe, visit: http://www.php.net/unsub.php


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

Reply via email to