Newsgroups: php.internals Path: news.php.net Xref: news.php.net php.internals:46859 Return-Path: Mailing-List: contact internals-help@lists.php.net; run by ezmlm Delivered-To: mailing list internals@lists.php.net Received: (qmail 92941 invoked from network); 21 Jan 2010 18:08:36 -0000 Received: from unknown (HELO lists.php.net) (127.0.0.1) by localhost with SMTP; 21 Jan 2010 18:08:36 -0000 X-Host-Fingerprint: 95.31.13.88 xdmitri2.static.corbina.ru Received: from [95.31.13.88] ([95.31.13.88:13754] helo=localhost.localdomain) by pb1.pair.com (ecelerity 2.1.1.9-wez r(12769M)) with ESMTP id 18/97-26239-228985B4 for ; Thu, 21 Jan 2010 13:08:35 -0500 Message-ID: <18.97.26239.228985B4@pb1.pair.com> To: internals@lists.php.net References: <3392.98.193.1264087265.squirrel@www.l-i-e.com> <5DA23CE5-D6A9-47D0-ADE6-48F0B58918AD@gmail.com> Date: Thu, 21 Jan 2010 21:08:32 +0300 Lines: 23 X-Priority: 3 X-MSMail-Priority: Normal X-Newsreader: Microsoft Outlook Express 6.00.2900.5843 X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2900.5579 X-RFC2646: Format=Flowed; Original X-Posted-By: 95.31.13.88 Subject: Re: [PHP-DEV] Dots and spaces in variable names are converted to underscores. From: dmda@yandex.ru ("jvlad") >> >> For BC, I suppose PHP could have *both* 'a.b' and 'a_b', or yet >> another php.ini flag (sorry!) to choose the behaviour. > >-1 from me. >I don't think we need to keep backward compatibility for this. PHP-6 is a >major release, after all. > >It would be absolutely enough to add optional var-name conversion to >extract()= By default extract _ignores_ variables with dots like a.b Even though register_globals should be removed, it does not mean that the default behaviour of extract should be changed. If it's _necessary_ to provide a way to mimic register_globals functionality, a special flag for it should be added, something like EXTR_MIMIC_REGISTER_GLOBALS that will replaces incorrect characters in the variable names with underscrores. In this case BC won't be broken.