Hi,

If we allow for trailing blanks, we'll allow the same set of chars that is 
already allowed for leading blanks.

I say'blanks' and not 'whitespaces', because here is the list currently allowed 
as leading blank (with ascii values) : Space (32) , tab (9) , linefeed (10), 
carriage-return (13), vertical tab (11), and form feed (12).


> -----Message d'origine-----
> De : yohg...@gmail.com [mailto:yohg...@gmail.com] De la part de Yasuo
> Ohgaki
> Envoyé : vendredi 27 février 2015 11:25
> À : Zeev Suraski
> Cc : Theodore Brown; internals@lists.php.net
> Objet : Re: [PHP-DEV] A different user perspective on scalar type
> declarations
> 
> Hi Zeev,
> 
> On Fri, Feb 27, 2015 at 2:48 AM, Zeev Suraski <z...@zend.com> wrote:
> 
> > You may have a point there.  As Francois said, he was in favor of allowing
> > leading and trailing spaces.  I'll definitely reconsider.
> >
> 
> If we consider existing code, leading/trailing spaces may need to be
> allowed.
> Without considering compatibility issues, leading/trailing spaces should be
> validated or removed by user input validation/filter code in the first
> place.
> 
> I think many users use "$" for the end of string data for regex, but it
> includes
> newline. To be precise, "\z" should be used for both PCRE and mbregex.
> 
> http://perldoc.perl.org/perlre.html
> 
> Trailing newline is invalid. Leading/trailing spaces may be considered as
> the
> same invalid data to be strict.
> 
> This is what I thought for this.
> I don't have strong opinion.
> 
> Regards,
> 
> --
> Yasuo Ohgaki
> yohg...@ohgaki.net


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

Reply via email to