Re: Fixing bug #18556 (was: Complete case-sensitivity in PHP)
| From: | Wim Wisselink | Date: | Sat, 05 May 2012 16:01:52 +0000 |
| Subject: | Re: Fixing bug #18556 (was: Complete case-sensitivity in PHP) | ||
| References: | 1 2 3 4 5 6 7 | Groups: | php.internals |
| Request: | Send a blank email to internals+get-60468@lists.php.net to get a copy of this message | ||
On 05/04/2012 11:22 PM, Galen Wright-Watson wrote:
On Fri, May 4, 2012 at 7:01 AM, C.Koy<can5koy@gmail.com> wrote:That also ran without error for me. I'm not sure how to account for the different behavior. Here are the details of the system that I'm using: $ uname -aOn 5/2/2012 10:03 PM, Galen Wright-Watson wrote:Try this with 5.2.17:On Wed, May 2, 2012 at 5:23 AM, C.Koy<can5koy@gmail.com> wrote: On 5/1/2012 9:11 PM, Galen Wright-Watson wrote:If literal function call precedes the function definition, that would fail too in 5.2.17, but not in 5.3.0. What has changed in this regard 5.2->5.3 ? Do you mean something like the following?On Thu, Apr 26, 2012 at 3:45 AM, C.Koy<can5koy@gmail.com> wrote:As of 5.3.0 this bug does not exist for function names. Only classes andinterfaces. Turns out, if you cause a function to be called dynamically by (e.g.)using a variable function, the bug will surface.<?php setlocale(LC_CTYPE, 'tr_TR'); function IJK() {} # succeeds IJK();<?php setlocale(LC_CTYPE, 'tr_TR'); IJK(); setlocale(LC_CTYPE, 'en_US'); function IJK() {echo __FUNCTION__, "\n";}I couldn't get it to generate an error under PHP 5.2.17. What am I missing?<?php setlocale(LC_CTYPE, 'tr_TR'); IJK(); function IJK() {}
Linux n10 3.2.6mtv10 #1 SMP Wed Mar 14 06:22:06 PDT 2012 x86_64 GNU/Linux $ php -v PHP 5.2.17 with Suhosin-Patch 0.9.7 (cli) (built: May 3 2012 12:16:32) Copyright (c) 1997-2009 The PHP Group Zend Engine v2.2.0, Copyright (c) 1998-2010 Zend Technologiessetlocale(LC_ALL, 'tr_TR.UTF-8'); I had the same issue.with Zend Optimizer v3.3.9, Copyright (c) 1998-2009, by ZendTechnologieswith Suhosin v0.9.32.1, Copyright (c) 2007-2010, by SektionEins GmbH Try to var_dump the setLocale and see if it return the specified locale or just 'false'. If false try the following: