Re: [PHP-DEV] SUMMARY: Array syntax
by Pierre other posts by this author
Jan 11 2008 5:03PM messages near this date
Re: [PHP-DEV] SUMMARY: Array syntax
|
Re: [PHP-DEV] SUMMARY: Array syntax
On Jan 12, 2008 1:54 AM, Jeff Griffiths <jeffg@[...].com> wrote:
> > if (1) {
> > $a = [
> > [
> > ['a' => 1, 3],
> > ($b = 3),
> > ]
> > ];
> > } else {
> > $a = [
> > [
> > ['b' => 1, 3]
> > ]
> > ];
> > }
>
> I agree, that's a bit nasty. =)
Like a string full of variables, arrays and objects can be unreadable :)
But I can't stop thinking about code like: [ [-1.0, 0.0, +1.0], [-2.0,
0.0 , +2.0], [-1.0, 0.0, +1.0]] and I will use this new syntax only
with such cases like this one :)
(variables in string are nice, when used with moderation/caution)
--
Pierre
http://blog.thepimp.net | http://www.libgd.org
--
PHP Internals - PHP Runtime Development Mailing List
To unsubscribe, visit: http://www.php.net/unsub.php
Thread:
johannes
Kouber Saparev
Stanislav Malyshev
Tomi Kaistila
Pierre
Steph Fox
Pierre
johannes
Rasmus Lerdorf
Pierre
Sam Barrow
Stanislav Malyshev
Sam Barrow
Antony Dovgal
Sam Barrow
Richard Lynch
Pierre
Antony Dovgal
Jeff Griffiths
Gregory Beaver
Antony Dovgal
Olivier Hill
Sam Barrow
Marcus Boerger
Pierre
Steph Fox
|