On Tue, 8 Jan 2013, Rafael Dohms wrote: > On Tue, Jan 8, 2013 at 10:37 PM, Stas Malyshev <smalys...@sugarcrm.com>wrote: > > > > Everyone I talked to who implemented annotations in docblocks did it > > > as hack because there is no native support. This is not something that > > > belongs to docblocks. It would be nice if you could take a look at the > > > c# doc, there are really good concepts there. > > > > I know why they did it, and we already discussed that stuff in the last > > annotation discussion. What I mean here is that presenting it as if the > > notion of meaningful comments is completely unheard of in PHP and nobody > > expects it is just wrong. Maybe it was so years ago, but it is > > definitely not true now - de-facto meaningful comments *are* the > > standard now, and have a lot of use, and nobody with any experience is > > surprised by them. Regardless of *why* is it so, it is a fact. > > That still does not make it the right place.
Huh? Why not? If it's something that everybody does (docblocks documenting methods/parameters), why change it? > Annotations went into docblocks because it was the only place > reflection could provide the needed information at runtime. Just > because we now treat docblocks as 1st class citizens does not mean > annotations should be there. > > Does that mean that annotations should be in docblocks and not in core > for the reason of "we all know docblocks exist". I would seriously expect > at the very least a stronger reason. These were some of the ones i heard > before: > > 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. cheers, Derick -- http://derickrethans.nl | http://xdebug.org Like Xdebug? Consider a donation: http://xdebug.org/donate.php twitter: @derickr and @xdebug Posted with an email client that doesn't mangle email: alpine -- PHP Internals - PHP Runtime Development Mailing List To unsubscribe, visit: http://www.php.net/unsub.php