Kalle Sommer Nielsen: > Hey Internals > > I've been wondering for quite some time why PHP doesn't allow you > to access arrays when you assign it to a value like in Javascript:
In many languages you get such functionality for free, because their parsers are written to accept: expression '[' expression ']' Thus, any expression that evaluates to an array can have '[]'. Javascript, Perl and C are just a few examples. The PHP parser is different. It requires a variable to the left of '['. Changing this is not as simple as changing one or two YACC rules. Wietse -- PHP Internals - PHP Runtime Development Mailing List To unsubscribe, visit: http://www.php.net/unsub.php