Re: [RFC] Reflection annotations reader

From: Date: Wed, 09 Jan 2013 16:35:18 +0000
Subject: Re: [RFC] Reflection annotations reader
References: 1 2 3 4 5 6 7 8  Groups: php.internals 
Request: Send a blank email to [email protected] to get a copy of this message
On 01/09/2013 04:16 AM, Derick Rethans wrote:
> On Tue, 8 Jan 2013, Rafael Dohms wrote:

>> 1. The syntax is crap: this is solvable, let's find the right syntax
> 
> Any extra syntax makes the PHP parser more complicated (and arguably 
> slower). I don't want to have it slower/more complex for some arbitrary 
> extra syntax just for some weird annotations.

This is my worry as well. Especially when it comes to opcode cache
support. Most of the patches I see these days completely ignore the
opcode cache side of things which needs to change. For any large
language-level change, any implementation that doesn't also include an
APC diff, or at least a very complete explanation of how it will be
generally supported by opcode caches just isn't complete.

In this case, attaching annotations/properties to classes will
definitely affect APC since we cache classes separately and NOP their
creation out of the op_arrays. So any extra opcodes will have to be
optimized out and the resulting class created and cached correctly.

-Rasmus


Thread (78 messages)

« previous php.internals (#64758) next »