Newsgroups: php.internals Path: news.php.net Xref: news.php.net php.internals:98113 Return-Path: Mailing-List: contact internals-help@lists.php.net; run by ezmlm Delivered-To: mailing list internals@lists.php.net Received: (qmail 27272 invoked from network); 1 Feb 2017 23:12:24 -0000 Received: from unknown (HELO lists.php.net) (127.0.0.1) by localhost with SMTP; 1 Feb 2017 23:12:24 -0000 Authentication-Results: pb1.pair.com header.from=cmbecker69@gmx.de; sender-id=pass Authentication-Results: pb1.pair.com smtp.mail=cmbecker69@gmx.de; spf=pass; sender-id=pass Received-SPF: pass (pb1.pair.com: domain gmx.de designates 212.227.17.20 as permitted sender) X-PHP-List-Original-Sender: cmbecker69@gmx.de X-Host-Fingerprint: 212.227.17.20 mout.gmx.net Received: from [212.227.17.20] ([212.227.17.20:56680] helo=mout.gmx.net) by pb1.pair.com (ecelerity 2.1.1.9-wez r(12769M)) with ESMTP id A2/07-51557-65B62985 for ; Wed, 01 Feb 2017 18:12:23 -0500 Received: from [192.168.2.109] ([79.243.112.140]) by mail.gmx.com (mrgmx103 [212.227.17.168]) with ESMTPSA (Nemesis) id 0LwJko-1cOf2F0owg-0187SM; Thu, 02 Feb 2017 00:12:17 +0100 To: =?UTF-8?Q?Johannes_Schl=c3=bcter?= , Rowan Collins References: <0c5fc86b-5050-fe73-7afa-b3e5a38ad370@gmail.com> <1485902801.28761.5.camel@kuechenschabe> <1485902993.28761.7.camel@kuechenschabe> Cc: PHP Internals Message-ID: <26102ac0-61f4-446e-7ac1-ccf879a58f94@gmx.de> Date: Thu, 2 Feb 2017 00:12:43 +0100 User-Agent: Mozilla/5.0 (Windows NT 10.0; WOW64; rv:45.0) Gecko/20100101 Thunderbird/45.7.0 MIME-Version: 1.0 In-Reply-To: <1485902993.28761.7.camel@kuechenschabe> Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Provags-ID: V03:K0:BTKZk2shVQ9rkc/wkPJlKX1yObx0DigcFbhxxY/RVveqhiF4xqw jdm/aRYmhlKXPfNy9IR1W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ings From: cmbecker69@gmx.de ("Christoph M. Becker") On 31.01.2017 at 23:49, Johannes Schlüter wrote: > On Tue, 2017-01-31 at 23:46 +0100, Johannes Schlüter wrote: > >> On Sun, 2017-01-29 at 19:33 +0000, Rowan Collins wrote: >>> Currently, if the constant FROB_ACTIVE is not defined, the code "echo >>> FROB_ACTIVE;" results in an E_NOTICE and the string 'FROB_ACTIVE' >>> being displayed. I would like to propose that this be changed to an >>> E_WARNING in PHP 7.2, and to an Error in PHP 8.0. >> >> related: There is another context where unquoted strings are used: >> >> $a = [ "foo" => "bar" ]; >> echo "Let's go and have a drink in a $a[foo]!"; This is explicitly mentioned in the RFC's "Unaffected PHP Functionality" section[1]. The RFC suggest to keep this shortcut. > Oh and there's another case: > > foo.php?a[foo]=bar > >> Any thoughts about continuing to allow that? > > I'm not saying we have to change those. But I believe the symmetry there > is part of the historic reason. Okay, but in neither case you've mentioned there are any potential pitfalls, i.e. `foo` can't be mistaken for a constant there, because the engine expects an unquoted string. [1] -- Christoph M. Becker