Newsgroups: php.internals Path: news.php.net Xref: news.php.net php.internals:78661 Return-Path: Mailing-List: contact internals-help@lists.php.net; run by ezmlm Delivered-To: mailing list internals@lists.php.net Received: (qmail 87112 invoked from network); 4 Nov 2014 18:17:34 -0000 Received: from unknown (HELO lists.php.net) (127.0.0.1) by localhost with SMTP; 4 Nov 2014 18:17:34 -0000 Authentication-Results: pb1.pair.com header.from=smalyshev@gmail.com; sender-id=pass Authentication-Results: pb1.pair.com smtp.mail=smalyshev@gmail.com; spf=pass; sender-id=pass Received-SPF: pass (pb1.pair.com: domain gmail.com designates 209.85.192.182 as permitted sender) X-PHP-List-Original-Sender: smalyshev@gmail.com X-Host-Fingerprint: 209.85.192.182 mail-pd0-f182.google.com Received: from [209.85.192.182] ([209.85.192.182:48138] helo=mail-pd0-f182.google.com) by pb1.pair.com (ecelerity 2.1.1.9-wez r(12769M)) with ESMTP id AB/3E-06676-D3819545 for ; Tue, 04 Nov 2014 13:17:33 -0500 Received: by mail-pd0-f182.google.com with SMTP id fp1so14014083pdb.41 for ; Tue, 04 Nov 2014 10:17:30 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=message-id:date:from:user-agent:mime-version:to:cc:subject :references:in-reply-to:content-type:content-transfer-encoding; bh=drcU7EP3HhIKuWBOwBmH8WPUFaABS85XnELj7+vICbI=; b=yujLZmsR6iBA9BlI4XP6clREYBzeR5Nmxwe7LmpraNlJ6YUKE4CvVGyCVPbqKCzjCI VwT7PT5F7rkFtJN4CaEFBk7c9bLMNQsoadrdsHXyHskcI4edPYmIKcf/hgUCrQaY2ikN j9gA+3BKcjqkHBRy58R7abqz8Kn+K2K523bX9yBKVc4PEg6bTrJcxnxkwXILHp3L0zhN Fs1PZFpB8zeNuWyFYXVBt7d28eFQVbYwbX2JhSw5qlgaLJuoQqoP8x7N1XZIg8mhDxdC 7jVR6XbSxHTPWiOG3dt0QVOiUn1dQlgyomLR+KojbkAjSOyY98knHApeG8NSdnSoGrjH xgMQ== X-Received: by 10.70.43.78 with SMTP id u14mr3230955pdl.166.1415125050369; Tue, 04 Nov 2014 10:17:30 -0800 (PST) Received: from Stass-MacBook-Pro.local (108-66-6-48.lightspeed.sntcca.sbcglobal.net. [108.66.6.48]) by mx.google.com with ESMTPSA id df1sm1063888pbb.2.2014.11.04.10.17.29 for (version=TLSv1.2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Tue, 04 Nov 2014 10:17:29 -0800 (PST) Message-ID: <54591838.8090502@gmail.com> Date: Tue, 04 Nov 2014 10:17:28 -0800 User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.7; rv:31.0) Gecko/20100101 Thunderbird/31.2.0 MIME-Version: 1.0 To: Pierre Joye CC: Levi Morrison , PHP internals , Larry Garfield References: <5457AF2F.90808@php.net> <5457BDB7.8070701@garfieldtech.com> <54589A8D.3020607@sugarcrm.com> In-Reply-To: Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 7bit Subject: Re: [PHP-DEV] Annotation PHP 7 From: smalyshev@gmail.com (Stas Malyshev) Hi! > All projects mentioned in this thread use: > http://doctrine-common.readthedocs.org/en/latest/reference/annotations.html > That makes a pretty good base spec. Reading it, it looks pretty big - strictly typed values, named parameters, default constructors linked to properties, support for enum types, support for typed arrays, separate constant syntax within annotations. These are all features not supported in PHP, and it seems a bit weird to me to have mini-language inside PHP that would support these. And, of course, arbitrary depth recursive annotations, and for some reason separate array syntax using {} and not []. Moreover, there's extensive checking for annotations with exceptions thrown if any of the above doesn't typecheck - I'm not even sure where that would fit in PHP parser.