Re: [PHP-DEV] [VOTE][RFC] Safe Casting Functions

2014-11-29 Thread Andrea Faulds
> On 19 Nov 2014, at 20:39, Andrea Faulds wrote: > > Good evening, > > I am putting the Safe Casting Functions RFC to a vote. > > https://wiki.php.net/rfc/safe_cast#vote > > Voting starts today (2014-11-19) and ends in 10 days’ time (2014-11-29). Good evening again, The final vote total com

Re: [PHP-DEV] [VOTE][RFC] Safe Casting Functions

2014-11-29 Thread Pascal Martin, AFUP
On 19/11/2014 21:39, Andrea Faulds wrote: I am putting the Safe Casting Functions RFC to a vote. https://wiki.php.net/rfc/safe_cast#vote Voting starts today (2014-11-19) and ends in 10 days’ time (2014-11-29). Hi, Judging from the discussions we've had with other members of AFUP, I'm guessi

Re: [PHP-DEV] [VOTE][RFC] Safe Casting Functions

2014-11-27 Thread Rowan Collins
Stanislav Malyshev wrote on 27/11/2014 01:03: Hi! I don't know if it would make a difference here, but I wonder if it would be sensible to add an "abstain" option in votes? That way, someone who has considered an RFC but not formed a strong opinion either way could register that fact. This coul

Re: [PHP-DEV] [VOTE][RFC] Safe Casting Functions

2014-11-26 Thread Stanislav Malyshev
Hi! > I don't know if it would make a difference here, but I wonder if it > would be sensible to add an "abstain" option in votes? That way, > someone who has considered an RFC but not formed a strong opinion > either way could register that fact. This could even be paired with You could register

Re: [PHP-DEV] [VOTE][RFC] Safe Casting Functions

2014-11-26 Thread Gwynne Raskind
On Nov 26, 2014, at 17:24, Andrea Faulds wrote: >> On 26 Nov 2014, at 23:00, Rowan Collins wrote: >>> So far only 15 people have voted, that’s very low for this kind of RFC. >>> >>> I’m tempted to extend voting for another week. It’s not likely to >>> change the outcome, but it would hopefully m

Re: [PHP-DEV] [VOTE][RFC] Safe Casting Functions

2014-11-26 Thread Andrea Faulds
> On 26 Nov 2014, at 23:00, Rowan Collins wrote: > >> So far only 15 people have voted, that’s very low for this kind of RFC. >> >> I’m tempted to extend voting for another week. It’s not likely to >> change the outcome, but it would hopefully mean more people vote. > > I don't know if it woul

Re: [PHP-DEV] [VOTE][RFC] Safe Casting Functions

2014-11-26 Thread Rowan Collins
On 26 November 2014 20:42:26 GMT, Andrea Faulds wrote: > >> On 19 Nov 2014, at 20:39, Andrea Faulds wrote: >> >> I am putting the Safe Casting Functions RFC to a vote. >> >> https://wiki.php.net/rfc/safe_cast#vote >> >> Voting starts today (2014-11-19) and ends in 10 days’ time >(2014-11-29).

Re: [PHP-DEV] [VOTE][RFC] Safe Casting Functions

2014-11-26 Thread Andrea Faulds
> On 19 Nov 2014, at 20:39, Andrea Faulds wrote: > > I am putting the Safe Casting Functions RFC to a vote. > > https://wiki.php.net/rfc/safe_cast#vote > > Voting starts today (2014-11-19) and ends in 10 days’ time (2014-11-29). So far only 15 people have voted, that’s very low for this kind

Re: [PHP-DEV] [VOTE][RFC] Safe Casting Functions

2014-11-24 Thread Andrea Faulds
> On 24 Nov 2014, at 16:08, Patrick ALLAERT wrote: > > > Le Wed Nov 19 2014 at 10:57:39 PM, Levi Morrison a écrit : > - PHP suffers a lot from function bloat and this RFC provides > multiple functions that do the same thing but differ only in how they > handle errors. A simple validation of

Re: [PHP-DEV] [VOTE][RFC] Safe Casting Functions

2014-11-24 Thread Patrick ALLAERT
Le Wed Nov 19 2014 at 10:57:39 PM, Levi Morrison a écrit : > > - PHP suffers a lot from function bloat and this RFC provides > multiple functions that do the same thing but differ only in how they > handle errors. A simple validation of "can this be safely cast to an > integer without dataloss?"

Re: [PHP-DEV] [VOTE][RFC] Safe Casting Functions

2014-11-21 Thread Lester Caine
On 21/11/14 02:10, Yasuo Ohgaki wrote: > To be honest, I have mixed feeling for this FRC. > Stricter type check is good. However, it requires runtime cost. One of the area where it is being held up as good practice is filtering data which is then passed to a database. With best practice on handlin

Re: [PHP-DEV] [VOTE][RFC] Safe Casting Functions

2014-11-21 Thread Andrea Faulds
> On 21 Nov 2014, at 03:02, Adam Harvey wrote: > >> The problem is that it’s the least bad of the available options. > > I disagree. To my mind, the best option right now (barring the status > quo, which realistically I'd prefer) would be the try_* functions > only. They line up with how ext/st

Re: [PHP-DEV] [VOTE][RFC] Safe Casting Functions

2014-11-20 Thread Yasuo Ohgaki
Hi Andrea, On Fri, Nov 21, 2014 at 11:06 AM, Andrea Faulds wrote: > Ideally, usage of these functions should be accompanied by some sort of > validation logic if necessary for the application. They aren’t validation > functions in themselves, they just prevent certain conversions that don’t > ma

Re: [PHP-DEV] [VOTE][RFC] Safe Casting Functions

2014-11-20 Thread Adam Harvey
On 20 November 2014 18:06, Andrea Faulds wrote: > >> On 21 Nov 2014, at 00:45, Adam Harvey wrote: >> >> On 19 November 2014 13:57, Levi Morrison wrote: >>> - The RFC does not address how this is different from >>> FILTER_VALIDATE_* from ext/filter. I know there was a mention of this >>> on the

Re: [PHP-DEV] [VOTE][RFC] Safe Casting Functions

2014-11-20 Thread Yasuo Ohgaki
Hi all, On Fri, Nov 21, 2014 at 10:48 AM, Marcio Almada wrote: > > Not a voter, but I don't really see the usefulness of this in core > either. > > True. This could be on packagist or a php ext, but should not be in > core. Main problem is that it carries too much ambiguity between > validation

Re: [PHP-DEV] [VOTE][RFC] Safe Casting Functions

2014-11-20 Thread Andrea Faulds
> On 21 Nov 2014, at 01:48, Marcio Almada wrote: > >> Not a voter, but I don't really see the usefulness of this in core either. > > True. This could be on packagist or a php ext, but should not be in > core. Main problem is that it carries too much ambiguity between > validation and coercion w

Re: [PHP-DEV] [VOTE][RFC] Safe Casting Functions

2014-11-20 Thread Andrea Faulds
> On 21 Nov 2014, at 00:45, Adam Harvey wrote: > > My -1 is pretty much the same as Levi's: > > On 19 November 2014 13:57, Levi Morrison wrote: >> - The RFC does not address how this is different from >> FILTER_VALIDATE_* from ext/filter. I know there was a mention of this >> on the mailing l

Re: [PHP-DEV] [VOTE][RFC] Safe Casting Functions

2014-11-20 Thread Marcio Almada
> Not a voter, but I don't really see the usefulness of this in core either. True. This could be on packagist or a php ext, but should not be in core. Main problem is that it carries too much ambiguity between validation and coercion while doesn't solve the real problem: strict typing. -- PHP In

Re: [PHP-DEV] [VOTE][RFC] Safe Casting Functions

2014-11-20 Thread David Muir
Not a voter, but I don't really see the usefulness of this in core either. Sent from my iPhone > On 21 Nov 2014, at 11:45 am, Adam Harvey wrote: > > My -1 is pretty much the same as Levi's: > >> On 19 November 2014 13:57, Levi Morrison wrote: >> - The RFC does not address how this is differ

Re: [PHP-DEV] [VOTE][RFC] Safe Casting Functions

2014-11-20 Thread Adam Harvey
My -1 is pretty much the same as Levi's: On 19 November 2014 13:57, Levi Morrison wrote: > - The RFC does not address how this is different from > FILTER_VALIDATE_* from ext/filter. I know there was a mention of this > on the mailing list, but the RFC should say why a tool that already > exists

Re: [PHP-DEV] [VOTE][RFC] Safe Casting Functions

2014-11-20 Thread Derick Rethans
On Wed, 19 Nov 2014, Andrea Faulds wrote: > Good evening, > > I am putting the Safe Casting Functions RFC to a vote. > > https://wiki.php.net/rfc/safe_cast#vote > > Voting starts today (2014-11-19) and ends in 10 days’ time (2014-11-29). > > Since some things might have changed since you last

Re: [PHP-DEV] [VOTE][RFC] Safe Casting Functions

2014-11-19 Thread Andrea Faulds
> On 19 Nov 2014, at 21:57, Levi Morrison wrote: > >> Since some things might have changed since you last read the RFC, I >> encourage you to read through it again. If there are any questions which >> have not yet been covered on the mailing list, feel free to ask them. > > - The RFC does no

Re: [PHP-DEV] [VOTE][RFC] Safe Casting Functions

2014-11-19 Thread Levi Morrison
> Since some things might have changed since you last read the RFC, I encourage > you to read through it again. If there are any questions which have not yet > been covered on the mailing list, feel free to ask them. - The RFC does not address how this is different from FILTER_VALIDATE_* from

Re: [PHP-DEV] [VOTE][RFC] Safe Casting Functions

2014-11-19 Thread Andrea Faulds
> On 19 Nov 2014, at 21:29, Lester Caine wrote: > > On 19/11/14 20:39, Andrea Faulds wrote: >> Since some things might have changed since you last read the RFC, I >> encourage you to read through it again. If there are any questions which >> have not yet been covered on the mailing list, feel

Re: [PHP-DEV] [VOTE][RFC] Safe Casting Functions

2014-11-19 Thread Lester Caine
On 19/11/14 20:39, Andrea Faulds wrote: > Since some things might have changed since you last read the RFC, I encourage > you to read through it again. If there are any questions which have not yet > been covered on the mailing list, feel free to ask them. What happens on a 32bit machine? -- L