Newsgroups: php.internals Path: news.php.net Xref: news.php.net php.internals:89404 Return-Path: Mailing-List: contact internals-help@lists.php.net; run by ezmlm Delivered-To: mailing list internals@lists.php.net Received: (qmail 98412 invoked from network); 25 Nov 2015 11:06:55 -0000 Received: from unknown (HELO lists.php.net) (127.0.0.1) by localhost with SMTP; 25 Nov 2015 11:06:55 -0000 Authentication-Results: pb1.pair.com smtp.mail=xinchen.h@zend.com; spf=pass; sender-id=pass Authentication-Results: pb1.pair.com header.from=laruence@php.net; sender-id=unknown Received-SPF: pass (pb1.pair.com: domain zend.com designates 209.85.213.45 as permitted sender) X-PHP-List-Original-Sender: xinchen.h@zend.com X-Host-Fingerprint: 209.85.213.45 mail-vk0-f45.google.com Received: from [209.85.213.45] ([209.85.213.45:33895] helo=mail-vk0-f45.google.com) by pb1.pair.com (ecelerity 2.1.1.9-wez r(12769M)) with ESMTP id 8F/E2-14932-A4695565 for ; Wed, 25 Nov 2015 06:06:51 -0500 Received: by vkbs1 with SMTP id s1so31999102vkb.1 for ; Wed, 25 Nov 2015 03:06:48 -0800 (PST) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:mime-version:in-reply-to:references:from:date :message-id:subject:to:cc:content-type; bh=auBH5WWHrf6NNswpXdbJP+ioK25HM+uBv8HAvxbG25c=; b=BUtPyFLlIm96NtTtkSddOLn2Qn/ujz7E9TScua6LZAefzAPronUF96UnsX5VIquRnw TqUwwtqk86Q7sBYDzcL8isefSWqmB+JPDhi+kRw/8gEy4yNmD+7IXALmhE/ntUw+T37+ XW7Hiez1SEwhXyu9LYmP/1juQEyB1Q8kmp5oc16dXpkkmcbGCA+Daq8gC+ZfiaXa1RHL EaKW9vVY1kehtXw56ckxf1NANunfEtsZbbV5GS7RsSFraMjMffgQ7mnkq7Lzrm6taquN OAyV1voegFhRPaerrBPD4Lg08UuOzRKoT749+QQKB9bbB+BndWfzX5DDgvG2LXvGE0QQ h2rA== X-Gm-Message-State: ALoCoQmZbqJpfFu2ioO7EF4uSqspbjk1cbQ2DVQU+ClQ0f+TyGmyDAgdG5GnwqnB8YDDEy53CqXSoXAGUShp1BVRuwJgz2o+X994DQ8ZxRQdoO9APFATmyqjOZXCs8J8kNJWh/iNIwbtDSn3az4vUxqdwN5kUd13RarQSTViTK9hp5Lfn7w4Ql4= X-Received: by 10.31.185.145 with SMTP id j139mr29991221vkf.99.1448449608035; Wed, 25 Nov 2015 03:06:48 -0800 (PST) Received: from mail-vk0-f48.google.com (mail-vk0-f48.google.com. [209.85.213.48]) by smtp.gmail.com with ESMTPSA id c190sm17966200vkc.16.2015.11.25.03.06.46 for (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Wed, 25 Nov 2015 03:06:47 -0800 (PST) Received: by vkfr145 with SMTP id r145so32317400vkf.0 for ; Wed, 25 Nov 2015 03:06:46 -0800 (PST) X-Received: by 10.31.139.84 with SMTP id n81mr24100422vkd.78.1448449606682; Wed, 25 Nov 2015 03:06:46 -0800 (PST) MIME-Version: 1.0 Received: by 10.31.229.7 with HTTP; Wed, 25 Nov 2015 03:06:27 -0800 (PST) In-Reply-To: References: <56547DFE.3080407@php.net> <565496FA.2010604@gmail.com> <84.DA.57156.C6B94565@pb1.pair.com> <56549E24.7030902@gmail.com> <5654BAE2.8020306@beccati.com> Date: Wed, 25 Nov 2015 19:06:27 +0800 X-Gmail-Original-Message-ID: Message-ID: To: Nikita Popov Cc: Bob Weinand , Anatol Belski , Andrea Faulds , Matteo Beccati , internals PHP Content-Type: multipart/alternative; boundary=001a114505fe48406505255b745f Subject: Re: [PHP-DEV] Scalar Type Declaration Syntax Weirdness From: laruence@php.net (Xinchen Hui) --001a114505fe48406505255b745f Content-Type: text/plain; charset=UTF-8 Hey: On Wed, Nov 25, 2015 at 5:57 PM, Nikita Popov wrote: > On Wed, Nov 25, 2015 at 4:47 AM, Xinchen Hui wrote: > >> Hey: >> >> >> >> On Wed, Nov 25, 2015 at 4:49 AM, Bob Weinand wrote: >> >> > > Am 24.11.2015 um 20:30 schrieb Matteo Beccati : >> > > >> > > On 24/11/2015 18:50, Andrea Faulds wrote: >> > >> There's no syntax change. We'd be adding another fatal error to >> > >> zend_compile.c triggered by a flag on the token. No messing around >> with >> > >> the parser. >> > >> >> > >> I understand your concern about the risk, but it's the kind of change >> > >> that wouldn't break anything without it being tremendously obvious. >> > > >> > > I agree and we should be still in time for RC8. >> > > >> > > >> > > Cheers >> > > -- >> > > Matteo Beccati >> > >> > Hey, >> > >> > I fixed the issue via >> > >> http://git.php.net/?p=php-src.git;a=commitdiff;h=569763cb1ac67f56e7743062ca8b3b7c650c1254 >> > >> > I think too this should go into PHP 7.0.0 as it is some type of a >> language >> > related change (even if not directly failing in parser...) >> > >> > >> I've made a improvement to the fix( >> >> https://github.com/php/php-src/commit/00865ae22f2c5fdee9e500ce79d442467e0a0899 >> ) >> , >> >> before this, \array will result a syntax , but \int result a compiler >> error, which seems a little in-consistent. >> > > Imho this additional change is not necessary, it only makes the parser > more complicated. > > However something missing from the original patch is handling of relative > names like namespace\int. Instead of checking for ast->attr == ZEND_NAME_FQ > it should check for ast->attr != ZEND_NAME_NOT_FQ. > > yeah, you are right, namespace\array still behavior difference from namespace\int. I am going to revert my part. thanks > Nikita > -- Xinchen Hui @Laruence http://www.laruence.com/ --001a114505fe48406505255b745f--