Newsgroups: php.internals Path: news.php.net Xref: news.php.net php.internals:50945 Return-Path: Mailing-List: contact internals-help@lists.php.net; run by ezmlm Delivered-To: mailing list internals@lists.php.net Received: (qmail 7598 invoked from network); 9 Dec 2010 12:40:51 -0000 Received: from unknown (HELO lists.php.net) (127.0.0.1) by localhost with SMTP; 9 Dec 2010 12:40:51 -0000 Authentication-Results: pb1.pair.com smtp.mail=adam@adamharvey.name; spf=pass; sender-id=pass Authentication-Results: pb1.pair.com header.from=adam@adamharvey.name; sender-id=pass Received-SPF: pass (pb1.pair.com: domain adamharvey.name designates 209.85.160.170 as permitted sender) X-PHP-List-Original-Sender: adam@adamharvey.name X-Host-Fingerprint: 209.85.160.170 mail-gy0-f170.google.com Received: from [209.85.160.170] ([209.85.160.170:65007] helo=mail-gy0-f170.google.com) by pb1.pair.com (ecelerity 2.1.1.9-wez r(12769M)) with ESMTP id B4/D1-32433-25EC00D4 for ; Thu, 09 Dec 2010 07:40:51 -0500 Received: by gyf2 with SMTP id 2so1429344gyf.29 for ; Thu, 09 Dec 2010 04:40:47 -0800 (PST) Received: by 10.100.201.15 with SMTP id y15mr6816317anf.259.1291898447686; Thu, 09 Dec 2010 04:40:47 -0800 (PST) MIME-Version: 1.0 Sender: adam@adamharvey.name Received: by 10.100.128.13 with HTTP; Thu, 9 Dec 2010 04:40:06 -0800 (PST) In-Reply-To: <4D00ABFE.5070403@hristov.com> References: <4D00ABFE.5070403@hristov.com> Date: Thu, 9 Dec 2010 20:40:06 +0800 X-Google-Sender-Auth: ykKJZBx8mNkNVMgEeCJz_xPx2as Message-ID: To: Andrey Hristov Cc: PHP Internals List Content-Type: text/plain; charset=UTF-8 Subject: Re: [PHP-DEV] Deprecating "global" + $GLOBALS, making $_REQUEST, $_GET, $_POST read-only From: aharvey@php.net (Adam Harvey) On 9 December 2010 18:14, Andrey Hristov wrote: > the topic says most of it. What do you think about deprecating the global > keyword and $GLOBALS with it? Together with this making $_REQUEST, $_GET and > $_POST read-only as they should be used only to read-only anyway. -1 here. No question that if you were developing a new language with similar design goals to PHP (but learning from the missteps), you'd probably make the superglobal analogues read only and skip the idea of $GLOBALS altogether, but there's just too much code out there that relies on these "features" working. Adam