Newsgroups: php.internals Path: news.php.net Xref: news.php.net php.internals:82881 Return-Path: Mailing-List: contact internals-help@lists.php.net; run by ezmlm Delivered-To: mailing list internals@lists.php.net Received: (qmail 19536 invoked from network); 16 Feb 2015 19:57:21 -0000 Received: from unknown (HELO lists.php.net) (127.0.0.1) by localhost with SMTP; 16 Feb 2015 19:57:21 -0000 Authentication-Results: pb1.pair.com smtp.mail=derick@php.net; spf=unknown; sender-id=unknown Authentication-Results: pb1.pair.com header.from=derick@php.net; sender-id=unknown Received-SPF: unknown (pb1.pair.com: domain php.net does not designate 82.113.146.227 as permitted sender) X-PHP-List-Original-Sender: derick@php.net X-Host-Fingerprint: 82.113.146.227 xdebug.org Linux 2.6 Received: from [82.113.146.227] ([82.113.146.227:55834] helo=xdebug.org) by pb1.pair.com (ecelerity 2.1.1.9-wez r(12769M)) with ESMTP id BD/CC-36518-E9B42E45 for ; Mon, 16 Feb 2015 14:57:18 -0500 Received: from localhost (localhost [IPv6:::1]) by xdebug.org (Postfix) with ESMTPS id 96DF010D593; Mon, 16 Feb 2015 19:57:13 +0000 (GMT) Date: Mon, 16 Feb 2015 19:57:13 +0000 (GMT) X-X-Sender: derick@whisky.home.derickrethans.nl To: Dmitry Stogov cc: PHP Internals , Nikita Popov , Guilherme Blanco , Pierrick CHARRON , Alexander Lisachenko , Pierre Joye , Zeev Suraski , Andi Gutmans , Joe Watkins , Yasuo Ohgaki , Sebastian Bergmann , Stanislav Malyshev , Rasmus Lerdorf In-Reply-To: Message-ID: References: User-Agent: Alpine 2.11 (DEB 23 2013-08-11) MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII Subject: Re: [PHP-DEV] Annotations in PHP7 From: derick@php.net (Derick Rethans) On Mon, 16 Feb 2015, Dmitry Stogov wrote: > hi, > > During discussion of different ways of implementing "Design by Contract" we > got an idea of using annotations. > > BTW: annotations are useful by their own and may be used for different > purposes. Support for annotations was proposed long time ago: > > https://wiki.php.net/rfc/annotations > https://wiki.php.net/rfc/annotations-in-docblock > https://wiki.php.net/rfc/reflection_doccomment_annotations > > HHVM already implemented similar concept > > http://docs.hhvm.com/manual/en/hack.attributes.php > > I made a quick and dirty PoC that shows how we may implement annotations in > PHP7 and how powerful they may be : > https://gist.github.com/dstogov/dbf2a8f46e43719bd2c2 Why didn't you pick the same syntax as hack? 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