Re: Regarding constructions like func()[0]

From: Date: Tue, 10 Nov 2009 08:41:38 +0000
Subject: Re: Regarding constructions like func()[0]
References: 1 2 3 4  Groups: php.internals 
Request: Send a blank email to internals+get-45986@lists.php.net to get a copy of this message
"Mathieu Suen" <mathieu.suen@easyflirt.com> wrote in message news:4AF91F92.4000101@easyflirt.com... > > Why isn't a mater of pushing the function call statement into a valuable > statement? > > I guess something like this: > > statement : > | value > | function_call; > > > value : > | valriable > | array_access > | method_send > | ...; ... > You also could push the new statement into the value so you can do: > > (new A())->foo(); > > or > > foo(new A()); > > -mthk How many conflicts does it bring? For example patch offered in this issue http://bugs.php.net/bug.php?id=50003 brought 5 new conflicts. Please note that in some cases conflicts will delay calls to zend_compile.c functions and therefore may bring real problems. IMHO it's not as simple as populating grammar elements. The results must be carefully tested to avoid BC breakage. just 2c

« previous php.internals (#45986) next »