Hi all,

I promise myself to not revamp this discussion again, but it wasn't me
this time!

@Etienne: That RFC is outdated.
Since the last feedback form internals list, a lot of changes have
been made to that RFC. Maybe I should update it ASAP so you can
clearly understand what have changed to be compatible with current PHP
syntax.

If you are interested, Pierrick moved all the recent developments to a
github repository, which can be reached here:
https://github.com/adoy/PHP-Annotations

Take a look at some tests:
https://github.com/adoy/PHP-Annotations/blob/master/tests/annotations/parser_021.phpt
https://github.com/adoy/PHP-Annotations/blob/master/tests/annotations/ReflectionParameter_getAnnotations_003.phpt
https://github.com/adoy/PHP-Annotations/blob/master/tests/annotations/ReflectionClass_getAnnotations_004.phpt

Also, there's even an alternative patch that support positioned
parameters instead of named ones.
We just have to reach an agreement with what PHP core want.

@Marcelo: While your proposal looks very good, it lacks of the support
to nested Annotation.
Consider how userland/framework would use your idea. For example,
Symfony2 supports validation of data inside classes inspired on
JSR-303 (Bean Validation).

Symfony2 takes an advantage of a library Doctrine group (which I'm a
core member) created by parsing docblocks. When we created this
parser, I created this RFC with the good intention that PHP could
benefit of this known feature to enhance current userland
developments.
The first thing you need is your application still running ok with and
without comments. This already breaks all suggestions of creating a
PECL extension of docblock parser.



I'd like to see what people think about it and make something "IN" on
next PHP major version.



Cheers,

On Sun, Mar 13, 2011 at 8:07 PM, Pierre Joye <pierre....@gmail.com> wrote:
> On Sun, Mar 13, 2011 at 11:02 PM, Marcelo Gornstein <marce...@gmail.com> 
> wrote:
>>> I don't believe the patch was anywhere near an accepted state back then,
>>> sadly.
>> Are you saying there wont be annotations in PHP? Is there any way to
>> contribute to make this feature accepted and available?
>
> No, only that no compromise has been reached on annotation support.
>
>
> --
> Pierre
>
> @pierrejoye | http://blog.thepimp.net | http://www.libgd.org
>
> --
> PHP Internals - PHP Runtime Development Mailing List
> To unsubscribe, visit: http://www.php.net/unsub.php
>
>



-- 
Guilherme Blanco
Mobile: +55 (16) 9215-8480
MSN: guilhermebla...@hotmail.com
São Paulo - SP/Brazil

--
PHP Internals - PHP Runtime Development Mailing List
To unsubscribe, visit: http://www.php.net/unsub.php

Reply via email to