Re: [PHP-DEV] [Discussion] Deprecate function sizeof()

2015-03-10 Thread Yasuo Ohgaki
Hi Pierre, On Tue, Mar 10, 2015 at 3:54 PM, Pierre Joye wrote: > I do not think it has anything to do with OO or procedural but the actual > gains. > > I see none here. > Why not? PHP is distributed with set of APIs. i.e. Libraries. Tight binding with libraries and language make library update d

Re: [PHP-DEV] [Discussion] Deprecate function sizeof()

2015-03-09 Thread Pierre Joye
On Mar 10, 2015 2:41 PM, "Yasuo Ohgaki" wrote: > > Hi Pierre and all, > > On Tue, Mar 10, 2015 at 11:59 AM, Pierre Joye wrote: >> >> On Tue, Mar 10, 2015 at 1:48 PM, Xinchen Hui wrote: >> > Hey: >> > >> > On Tue, Mar 10, 2015 at 10:07 AM, Yasuo Ohgaki wrote: >> >> Hi Reeze, >> >> >> >> On Mon,

Re: [PHP-DEV] [Discussion] Deprecate function sizeof()

2015-03-09 Thread Yasuo Ohgaki
Hi Pierre and all, On Tue, Mar 10, 2015 at 11:59 AM, Pierre Joye wrote: > On Tue, Mar 10, 2015 at 1:48 PM, Xinchen Hui wrote: > > Hey: > > > > On Tue, Mar 10, 2015 at 10:07 AM, Yasuo Ohgaki > wrote: > >> Hi Reeze, > >> > >> On Mon, Mar 9, 2015 at 12:56 PM, reeze wrote: > >> > >>> It is a depr

Re: [PHP-DEV] [Discussion] Deprecate function sizeof()

2015-03-09 Thread Pierre Joye
On Tue, Mar 10, 2015 at 1:48 PM, Xinchen Hui wrote: > Hey: > > On Tue, Mar 10, 2015 at 10:07 AM, Yasuo Ohgaki wrote: >> Hi Reeze, >> >> On Mon, Mar 9, 2015 at 12:56 PM, reeze wrote: >> >>> It is a deprecated warning I won't break code I think. >>> >>> This could makes those project more maintain

Re: [PHP-DEV] [Discussion] Deprecate function sizeof()

2015-03-09 Thread Xinchen Hui
Hey: On Tue, Mar 10, 2015 at 10:07 AM, Yasuo Ohgaki wrote: > Hi Reeze, > > On Mon, Mar 9, 2015 at 12:56 PM, reeze wrote: > >> It is a deprecated warning I won't break code I think. >> >> This could makes those project more maintainable (new PHP programmer could >> be easier to maintain the code

Re: [PHP-DEV] [Discussion] Deprecate function sizeof()

2015-03-09 Thread Yasuo Ohgaki
Hi Reeze, On Mon, Mar 9, 2015 at 12:56 PM, reeze wrote: > It is a deprecated warning I won't break code I think. > > This could makes those project more maintainable (new PHP programmer could > be easier to maintain the code without surprise), and it will be trivial to > fix this. We could move

Re: [PHP-DEV] [Discussion] Deprecate function sizeof()

2015-03-08 Thread reeze
On 9 March 2015 at 06:44, Pierre Joye wrote: > On Sun, Mar 8, 2015 at 2:51 AM, reeze wrote: > > Hi internals, > > > > I'd like to deprecate function: sizeof() [1][2], which is an alias of > > count(). some people > > expect it return the memory size of the variable. > > > > The doc page's[1] use

Re: [PHP-DEV] [Discussion] Deprecate function sizeof()

2015-03-08 Thread reeze
On 8 March 2015 at 09:39, Yasuo Ohgaki wrote: > Hi all, > > On Sun, Mar 8, 2015 at 5:41 AM, Stanislav Malyshev > wrote: > >> > I'd like to deprecate function: sizeof() [1][2], which is an alias of >> > count(). some people >> > expect it return the memory size of the variable. >> >> Why? So, som

Re: [PHP-DEV] [Discussion] Deprecate function sizeof()

2015-03-08 Thread reeze
Hi, On 8 March 2015 at 00:41, Kalle Sommer Nielsen wrote: > Hi > > 2015-03-07 16:51 GMT+01:00 reeze : > > Hi internals, > > > > I'd like to deprecate function: sizeof() [1][2], which is an alias of > > count(). some people > > expect it return the memory size of the variable. > > > > The doc pag

Re: [PHP-DEV] [Discussion] Deprecate function sizeof()

2015-03-08 Thread Pierre Joye
On Sun, Mar 8, 2015 at 2:51 AM, reeze wrote: > Hi internals, > > I'd like to deprecate function: sizeof() [1][2], which is an alias of > count(). some people > expect it return the memory size of the variable. > > The doc page's[1] user contributed notes indicate that too. > > What do you think?

Re: [PHP-DEV] [Discussion] Deprecate function sizeof()

2015-03-07 Thread Yasuo Ohgaki
Hi all, On Sun, Mar 8, 2015 at 5:41 AM, Stanislav Malyshev wrote: > > I'd like to deprecate function: sizeof() [1][2], which is an alias of > > count(). some people > > expect it return the memory size of the variable. > > Why? So, some people are wrong, why we need to mess with the language to

Re: [PHP-DEV] [Discussion] Deprecate function sizeof()

2015-03-07 Thread Stanislav Malyshev
Hi! > I'd like to deprecate function: sizeof() [1][2], which is an alias of > count(). some people > expect it return the memory size of the variable. Why? So, some people are wrong, why we need to mess with the language to accommodate them? I don't think it is a good idea. -- Stas Malyshev sma

Re: [PHP-DEV] [Discussion] Deprecate function sizeof()

2015-03-07 Thread Bostjan Skufca
On 7 March 2015 at 20:42, Kalle Sommer Nielsen wrote: > Hi > > Well we could make count()/sizeof() work for strings, so that if: > C:\> php -r "echo sizeof('abc');" > 3 > > although it would not really accomplish much imo., I think it is more > of what background you come from that makes the most

Re: [PHP-DEV] [Discussion] Deprecate function sizeof()

2015-03-07 Thread Kalle Sommer Nielsen
Hi 2015-03-07 18:35 GMT+01:00 Sebastian B.-Hagensen : > Hi, > I don't think the alias make sense and is really misleading and I've > seen sizeof("abc"); often enough (Don't get me wrong that's equally > bad with count, but sizeof encourages that usage, imo). > Having two functions that do exactly

Re: [PHP-DEV] [Discussion] Deprecate function sizeof()

2015-03-07 Thread Lester Caine
On 07/03/15 17:35, Sebastian B.-Hagensen wrote: > On the other side: Removal of sizeof is doable with a patch release > for almost all projects and shouldn't really require more than 5 to 10 > minutes (+ time to review the diff) for most projects. If taken in conjunction with tidying up the IEEE C

Re: [PHP-DEV] [Discussion] Deprecate function sizeof()

2015-03-07 Thread Sebastian B.-Hagensen
Hi, 2015-03-07 17:41 GMT+01:00 Kalle Sommer Nielsen : > I'm a big -1 on this, while I know it returns the memory size in a C > perspective, I think it makes perfect sense to remain an alias, it > would break lots of applications for a very tiny to nothing gain. I don't think the alias make sense

Re: [PHP-DEV] [Discussion] Deprecate function sizeof()

2015-03-07 Thread Kalle Sommer Nielsen
Hi 2015-03-07 16:51 GMT+01:00 reeze : > Hi internals, > > I'd like to deprecate function: sizeof() [1][2], which is an alias of > count(). some people > expect it return the memory size of the variable. > > The doc page's[1] user contributed notes indicate that too. > > What do you think? 'm a bi

[PHP-DEV] [Discussion] Deprecate function sizeof()

2015-03-07 Thread reeze
Hi internals, I'd like to deprecate function: sizeof() [1][2], which is an alias of count(). some people expect it return the memory size of the variable. The doc page's[1] user contributed notes indicate that too. What do you think? [1] http://php.net/sizeof [2] https://github.com/php/php