Timm Friebe wrote:
> Come on, you don't need a long trainride for that.
I could not resist, initial code (no actual annotation parsing, yet!) is
here:
http://sebastian-bergmann.de/stuff/Annotation/Reflection/Annotation.phps
http://sebastian-bergmann.de/stuff/Annotation/Reflection/Class.phps
Timm Friebe wrote:
> Come on, you don't need a long trainride for that.
For the essence of it, no. But to make it "beautiful" ... we'll see. :-)
--
Sebastian Bergmann http://www.sebastian-bergmann.de/
GnuPG Key: 0xB85B5D69 / 27A7 2B14 09E4 98CD 6277 0E5B 6867 C514 B85B 5D6
Hi,
[...]
> I would like to see a PEAR (or even PECL) package that
> provides this functionality. I might even write it myself
> (given that I have a couple of long train rides coming up I
> will probably do this anyhow :-)
Come on, you don't need a long trainride for that.
http://sitten-p
>The PHP development team is usually against these kinds of OOP syntax sugar
>additions, search Google / the archives for:
I don't think this is syntactic sugar, it goes deeper into the language than
that if done right.
I like your userland implementation, but it will get slow once you start
w
Timm Friebe wrote:
> Extend (or wrap) the reflection classes and add:
>
> MyClass::getAnnotations()
> MyMethod::getAnnotations()
> MyProperty::getAnnotations()
>
> In those, parse the sourcecode with ext/tokenizer and extract all
> comments beginning with the string "#[", push them into a
Hi,
[...]
> I am playing around with an extension to the Zend Engine 2 to
> allow class properties and methods to be tagged with
> attributes. These attributes would then be accessible through
> the Reflection classes:
The PHP development team is usually against these kinds of OOP syntax sugar