RE: [PHP-DEV] [SPAM] Re: [PHP-DEV] Syntactic improvement to array

2007-02-07 Thread Ford, Mike
> -Original Message- > From: Robert Cummings [mailto:[EMAIL PROTECTED] > Sent: 06 February 2007 16:09 > > I know how much you want to feel special, but here's the > definition of "read". Your description of how you interpret > what you see falls into this definition: Oh, no fair! You'v

RE: [PHP-DEV] [SPAM] Re: [PHP-DEV] Syntactic improvement to array

2007-02-06 Thread Robert Cummings
On Tue, 2007-02-06 at 15:41 +, Ford, Mike wrote: > On 06 February 2007 14:42, Robert Cummings wrote: > > > On Tue, 2007-02-06 at 14:08 +, Ford, Mike wrote: > > > On 05 February 2007 17:29, Brian Moon wrote: > > > > That is why you have coding standards. Our doucment states that > > > > th

RE: [PHP-DEV] [SPAM] Re: [PHP-DEV] Syntactic improvement to array

2007-02-06 Thread Ford, Mike
On 06 February 2007 14:42, Robert Cummings wrote: > On Tue, 2007-02-06 at 14:08 +, Ford, Mike wrote: > > On 05 February 2007 17:29, Brian Moon wrote: > > > That is why you have coding standards. Our doucment states that > > > this should be written as: > > > > > > $a = array( > > > 1 => a

Re: [PHP-DEV] [SPAM] Re: [PHP-DEV] Syntactic improvement to array

2007-02-06 Thread Alain Williams
On Tue, Feb 06, 2007 at 04:16:28PM +0100, Christian Schneider wrote: > Alain Williams wrote: > > Anyway: it makes php look like perl -- and that would never do :-) > > Can we please stop that FUD? (even if it is meant as a joke) No: it was NOT a serious point. What is wrong with the occasional gr

Re: [PHP-DEV] [SPAM] Re: [PHP-DEV] Syntactic improvement to array

2007-02-06 Thread Christian Schneider
Alain Williams wrote: > Anyway: it makes php look like perl -- and that would never do :-) Can we please stop that FUD? (even if it is meant as a joke) ... if at all then you might say it looks like Javascript, Python or Ruby. Perl uses an ugly mix of () and [] to emulate multi-dimensional arrays

Re: [PHP-DEV] [SPAM] Re: [PHP-DEV] Syntactic improvement to array

2007-02-06 Thread Alain Williams
On Tue, Feb 06, 2007 at 09:41:34AM -0500, Robert Cummings wrote: > On Tue, 2007-02-06 at 14:08 +, Ford, Mike wrote: > > On 05 February 2007 17:29, Brian Moon wrote: > > > That is why you have coding standards. Our doucment states that this > > > should be written as: > > > > > > $a = array(

RE: [PHP-DEV] [SPAM] Re: [PHP-DEV] Syntactic improvement to array

2007-02-06 Thread Robert Cummings
On Tue, 2007-02-06 at 14:08 +, Ford, Mike wrote: > On 05 February 2007 17:29, Brian Moon wrote: > > That is why you have coding standards. Our doucment states that this > > should be written as: > > > > $a = array( > > 1 => array('pears', 'apples'), > > 2 => array('juice', 'oranges')

RE: [PHP-DEV] [SPAM] Re: [PHP-DEV] Syntactic improvement to array

2007-02-06 Thread Ford, Mike
On 05 February 2007 17:29, Brian Moon wrote: > Ford, Mike wrote: > > > I don't find: > > > > > > $a = [1 => ['pears', 'apples'], 2 => ['juice', 'oranges']]; > > > > > > any less readable than: > > > > > > $a = array(1 => array('pears', 'apples'), 2 => array('juice', > > > 'oranges')); > > > >

Re: [PHP-DEV] [SPAM] Re: [PHP-DEV] Syntactic improvement to array

2007-02-05 Thread Brian Moon
Ford, Mike wrote: I don't find: $a = [1 => ['pears', 'apples'], 2 => ['juice', 'oranges']]; any less readable than: $a = array(1 => array('pears', 'apples'), 2 => array('juice', 'oranges')); Quite the opposite actually :) Me too - I go beyond Edin on this one, as I find the array() versio

RE: [PHP-DEV] [SPAM] Re: [PHP-DEV] Syntactic improvement to array

2007-02-05 Thread Ford, Mike
On 04 February 2007 18:38, Edin Kadribasic wrote: > Lukas Kahwe Smith wrote: > > Yes, you will come across it if its added. > > I find the Javascript syntax confusing to read as well. However more > > importantly I do not see the point in adding this sugar to save 5 > > chars. > > Nested arrays

Re: [PHP-DEV] [SPAM] Re: [PHP-DEV] Syntactic improvement to array

2007-02-04 Thread Richard Lynch
On Sun, February 4, 2007 2:46 pm, Stefan Walk wrote: > Steph wrote: >> Hi Stas, >> >>> By pure coincidence, I was doing a bunch of javascript work lately >>> too, and I find [] syntax OK. From readability POV it's not much >>> difference, but much less clutter if you have really massive data >>> ar

Re: [PHP-DEV] [SPAM] Re: [PHP-DEV] Syntactic improvement to array

2007-02-04 Thread Robert Cummings
On Sun, 2007-02-04 at 19:38 +0100, Edin Kadribasic wrote: > Lukas Kahwe Smith wrote: > > Yes, you will come across it if its added. > > I find the Javascript syntax confusing to read as well. However more > > importantly I do not see the point in adding this sugar to save 5 chars. > > Nested array

[PHP-DEV] [SPAM] Re: [PHP-DEV] [SPAM] Re: [PHP-DEV] Syntactic improvement to array

2007-02-04 Thread Steph
Fine, but in javascript there is only one option. That's the difference. - Steph a = Array(1,2,3) a = [1,2,3] I stand corrected. Apologies for the noise. - Steph -- PHP Internals - PHP Runtime Development Mailing List To unsubscribe, visit: http://www.php.net/unsub.php

Re: [PHP-DEV] [SPAM] Re: [PHP-DEV] Syntactic improvement to array

2007-02-04 Thread Stefan Walk
Steph wrote: > Hi Stas, > >> By pure coincidence, I was doing a bunch of javascript work lately >> too, and I find [] syntax OK. From readability POV it's not much >> difference, but much less clutter if you have really massive data >> array - no array() things which take half of the space. > > F

[PHP-DEV] [SPAM] Re: [PHP-DEV] Syntactic improvement to array

2007-02-04 Thread Steph
Hi Stas, By pure coincidence, I was doing a bunch of javascript work lately too, and I find [] syntax OK. From readability POV it's not much difference, but much less clutter if you have really massive data array - no array() things which take half of the space. Fine, but in javascript there

Re: [PHP-DEV] [SPAM] Re: [PHP-DEV] Syntactic improvement to array

2007-02-04 Thread Derick Rethans
On Sun, 4 Feb 2007, Edin Kadribasic wrote: > I don't find: > > $a = [1 => ['pears', 'apples'], 2 => ['juice', 'oranges']]; > > any less readable than: > > $a = array(1 => array('pears', 'apples'), 2 => array('juice', 'oranges')); > > Quite the opposite actually :) That's a personal thing, and

Re: [PHP-DEV] [SPAM] Re: [PHP-DEV] Syntactic improvement to array

2007-02-04 Thread Edin Kadribasic
Lukas Kahwe Smith wrote: > Yes, you will come across it if its added. > I find the Javascript syntax confusing to read as well. However more > importantly I do not see the point in adding this sugar to save 5 chars. Nested arrays become very unreadable with the current PHP syntax. I think killing

Re: [PHP-DEV] [SPAM] Re: [PHP-DEV] Syntactic improvement to array

2007-02-04 Thread Lukas Kahwe Smith
Steph wrote: On 2/4/07, Ilia Alshanetsky <[EMAIL PROTECTED]> wrote: I personally find array extremely clear, in recent weeks I had to do A LOT of JavaScript work where the array syntax works in a manner you suggest for PHP and its a massive pain. It does not make for a very clear code. I think t

[PHP-DEV] [SPAM] Re: [PHP-DEV] Syntactic improvement to array

2007-02-04 Thread Steph
On 2/4/07, Ilia Alshanetsky <[EMAIL PROTECTED]> wrote: I personally find array extremely clear, in recent weeks I had to do A LOT of JavaScript work where the array syntax works in a manner you suggest for PHP and its a massive pain. It does not make for a very clear code. I think the syntax you

[PHP-DEV] [SPAM] Re: [PHP-DEV] Syntactic improvement to array

2007-02-04 Thread Steph
I personally find array extremely clear, in recent weeks I had to do A LOT of JavaScript work where the array syntax works in a manner you suggest for PHP and its a massive pain. It does not make for a very clear code. I think the syntax you propose is extremely confusing and we should stick