Re: [VOTE][RFC] intdiv()

From: Date: Thu, 31 Jul 2014 08:53:21 +0000
Subject: Re: [VOTE][RFC] intdiv()
References: 1 2  Groups: php.internals 
Request: Send a blank email to internals+get-76288@lists.php.net to get a copy of this message
On 30 July 2014 18:51, Adam Harvey <aharvey@php.net> wrote: > -1 explanation: I don't think %% is clear enough, the only sensible > syntax choice (//) is unavailable to us, and I think the utility of > having it baked into the language as an operator is pretty minimal > regardless (I coded a lot of Python for scientific research in a > previous job, and I don't think I ever used //, and you'd think that's > the place where you'd use it). > > +1 on the function, though — quick searches on Ohloh and Github > suggest that there are a grand total of three open source projects > that implement a global intdiv() function. Seems safe enough. > > Adam > This describes my voting choice exactly. I'm not against the idea of an operator, but %% is not the right operator choice for me. I could live with /% but it still doesn't feel quite right. I don't have a practical implementable suggestion for an alternative, so I guess we'll just have to live without it. Of course, this does not preclude us from introducing this in the future if someone comes up with a better idea :-) Thanks, Chris

« previous php.internals (#76288) next »