2015-02-16 14:19 GMT+03:00 Dmitry Stogov <dmi...@zend.com>:

> annotations ::= { annotation }.
> annotation   ::= '<' STRING '>' | '<' STRING '(' expr ')' '>'.
>
> where <expr> is regular PHP expression.



Hello!

Really like this syntax, actually you steal my thoughts )) I want to call
this metadata, not an annotations. Just key-value storage for any top-level
elements (namespaces, classes, functions, methods, properties, etc).

Value can by anything, acceptable by PHP parser, then it will be possible
to provide an API to get this AST node "as-is" and to add a logic layer on
top of this. (I'm still waiting for the RFC karma)

For annotations, it should be possible to use <<ClassName::class>>
constant. Additionally, nested metadata should be supported.

Thanks!

Reply via email to