Newsgroups: php.internals Path: news.php.net Xref: news.php.net php.internals:49668 Return-Path: Mailing-List: contact internals-help@lists.php.net; run by ezmlm Delivered-To: mailing list internals@lists.php.net Received: (qmail 71237 invoked from network); 15 Sep 2010 16:17:55 -0000 Received: from unknown (HELO lists.php.net) (127.0.0.1) by localhost with SMTP; 15 Sep 2010 16:17:55 -0000 Authentication-Results: pb1.pair.com smtp.mail=guilhermeblanco@gmail.com; spf=pass; sender-id=pass Authentication-Results: pb1.pair.com header.from=guilhermeblanco@gmail.com; sender-id=pass; domainkeys=bad Received-SPF: pass (pb1.pair.com: domain gmail.com designates 74.125.82.54 as permitted sender) DomainKey-Status: bad X-DomainKeys: Ecelerity dk_validate implementing draft-delany-domainkeys-base-01 X-PHP-List-Original-Sender: guilhermeblanco@gmail.com X-Host-Fingerprint: 74.125.82.54 mail-ww0-f54.google.com Received: from [74.125.82.54] ([74.125.82.54:38237] helo=mail-ww0-f54.google.com) by pb1.pair.com (ecelerity 2.1.1.9-wez r(12769M)) with ESMTP id E9/9A-33442-3B1F09C4 for ; Wed, 15 Sep 2010 12:17:55 -0400 Received: by wwb39 with SMTP id 39so393978wwb.11 for ; Wed, 15 Sep 2010 09:17:52 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:mime-version:received:received:in-reply-to :references:date:message-id:subject:from:to:cc:content-type :content-transfer-encoding; bh=xUkqmQqkuNXeCOOydpNEYyha0ho186W+o3GeEEg1xTI=; b=hvOvsnNnYOpGAgfYc9vGnEweQW+Ta9bhWX+kbIqiBV45qvIx4f5bI8AkXQ13X/M2+T zvGyzngI9biKLkTYuC8WQSTQ4zouOp5uJDmKaYwUwDvFOnEeud0+nTqJnPmRuRRgQGOW +i/7aJltd/DbS3fUwEOTMbH5H+Ll5wt/TdNd0= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=mime-version:in-reply-to:references:date:message-id:subject:from:to :cc:content-type:content-transfer-encoding; b=HToXnmjaL748yL6AgGwwu/rh419m1Q5dQSuUAr5RO5YgnNPkyEPCYkG/KUFKIKVjvM apkXy2XDHQzA3YRvS6a4wtbDh9Q/yNu35/09MP3XORgM2yCnIowE0UmyECkw7Cswambo zeeE6yy1luKkIc7kEx2zp+cqO9ofU+qMcqyss= MIME-Version: 1.0 Received: by 10.216.38.20 with SMTP id z20mr1461309wea.108.1284567472377; Wed, 15 Sep 2010 09:17:52 -0700 (PDT) Received: by 10.216.55.130 with HTTP; Wed, 15 Sep 2010 09:17:49 -0700 (PDT) In-Reply-To: <4C9095D5.1050206@toolpark.com> References: <39505F13-655A-43AF-941E-77750B7F7201@gmail.com> <001601cb543a$d81ebac0$885c3040$@com> <4C8FC695.2060800@sugarcrm.com> <4C8FD72B.1070108@sugarcrm.com> <4C906333.4030204@sugarcrm.com> <7.0.1.0.2.20100915085504.17eab4d8@zend.com> <12617cf66ae07d7a2fd79a293ed69b85@beberlei.de> <4C9095D5.1050206@toolpark.com> Date: Wed, 15 Sep 2010 13:17:49 -0300 Message-ID: To: Lars Schultz Cc: internals@lists.php.net Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: quoted-printable Subject: Re: [PHP-DEV] Re: Re: PHP Annotations RFC + Patch From: guilhermeblanco@gmail.com (Guilherme Blanco) It's curious that you keep complaining about new syntax and propose a new one at the same time. [Foo] introduces new concept, use /** @Foo */ or /** [Foo] */ instead. What's the point then? I think meta programming is not and would never be part of comment. As previously said, docblock means documentation, without any meaning to parser, entirely human readable and totally removable without affecting overall execution. Something that HAS a meaning to execution means something out of the userland comments. Point made. Cheers, On Wed, Sep 15, 2010 at 6:45 AM, Lars Schultz w= rote: > listen to this man;) I think he's on to something. I don't see any proble= m > with that aproach and both parties would be satisfied, no? > > Am 15.09.2010 10:45, schrieb Benjamin Eberlei: >> >> Hi Zeev and Stas, >> >> >> >> I wouldnt mind extending doc block metadata support instead of adding a >> >> new syntax. >> >> >> >> I agree with you that PHP Docs allow metadata and they can be used for >> >> that (and some people do, including me), however what the annotation pat= ch >> >> + rfc tries to achieve is something going beyong $refl->getDocComment() >> >> returning a string only. The string only return leads to hunderets of >> >> different approaches for annotating metadata in all the different >> >> frameworks and libraries. A single unified syntax would be benefitial. >> >> >> >> That is why I don't know if it will even be possible to extend the doc >> >> blocks in a generic way that does not break half the applications out >> >> there. >> >> >> >> When extending doc-blocks there is probably new method required >> >> $refl->getParsedDocComment() which then returns an array of metadata for >> >> that particular refl instance. Now here the syntax would be a problem, c= an >> >> we find something that does not break for all the different usages of >> >> docblocks out there? Since the method/parsing would be nested, on reques= t >> >> only it wouldnt break any application that does not use parsed doc >> >> comments. However for applications that do, a syntax needs to be found >> >> that: >> >> >> >> 1. does not break for various type hinting doc syntaxes >> >> 2. does not break for various commenting styles >> >> >> >> Can someone come up with additional pitfalls? >> >> >> >> greetings, >> >> Benjamin >> >> >> >> On Wed, 15 Sep 2010 08:55:55 +0200, Zeev Suraski =C2=A0wr= ote: >> >> >> >> =C2=A0 =C2=A0 At 08:09 15/09/2010, Stas Malyshev wrote: >> >> >> >> =C2=A0 =C2=A0 =C2=A0 =C2=A0 Phpdocs aren't "user documentation" only, no= t for a long time (I >> >> mean the concept, not the particular application called phpDocumentor, o= f >> >> course). They are being used as metadata in many places. You could argue >> >> that's misguided but you can't ignore the fact that's what people do. Th= e >> >> "goals and usages" of those tags are exactly metadata - and regardless o= f >> >> the annotations, I'd be happy if Reflection recognized it finally (by >> >> integrating some kind of phpdoc tag parser). >> >> >> >> =C2=A0 =C2=A0 I second that word for word. FWIW, I don't see it as misgu= ided at all. >> >> Zeev >> > > > -- > PHP Internals - PHP Runtime Development Mailing List > To unsubscribe, visit: http://www.php.net/unsub.php > > --=20 Guilherme Blanco Mobile: +55 (16) 9215-8480 MSN: guilhermeblanco@hotmail.com S=C3=A3o Paulo - SP/Brazil