Fatal PHP error if class/interface name has letter 'I' and locale set to tr_TR.utf8
Bug #988963 reported by
Seyfi
This bug report is a duplicate of:
Bug #338720: Function lookup problem after calling setlocale(LC_ALL, "tr_TR").
Edit
Remove
This bug affects 1 person
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
php |
Unknown
|
Unknown
|
|||
php5 (Ubuntu) |
Confirmed
|
Medium
|
Unassigned |
Bug Description
Description: Ubuntu 11.10
Release: 11.10
php5-cli:
Installed: 5.3.6-13ubuntu3.6
Candidate: 5.3.6-13ubuntu3.6
Test case #1:
<?php
setlocale(LC_ALL, 'tr_TR.utf8') or exit("tr_TR locale needed to run this test".PHP_EOL);
class IClass { }
$inst = new IClass;
?>
produces the following:
PHP Fatal error: Class 'IClass' not found...
Test case #2:
<?php
setlocale(LC_ALL, 'tr_TR.utf8') or exit("tr_TR locale needed to run this test".PHP_EOL);
interface Intf { }
class MyClass implements Intf { }
?>
produces the following:
PHP Fatal error: Interface 'Intf' not found...
To post a comment you must log in.
This is definitely a weird one. Not sure why the locale would cause that.
$ sudo locale-gen tr_TR.UTF-8 mirrors. kernel. org/ubuntu/ precise/main amd64 Packages dpkg/status
Generating locales...
tr_TR.UTF-8... done
Generation complete.
$ php
<?php
setlocale(LC_ALL, 'tr_TR.utf8') or exit("tr_TR locale needed to run this test".PHP_EOL);
class IClass { }
$inst = new IClass;
PHP Fatal error: Class 'IClass' not found in - on line 4
$ apt-cache policy php5-cli
php5-cli:
Installed: 5.3.10-1ubuntu3
Candidate: 5.3.10-1ubuntu3
Version table:
*** 5.3.10-1ubuntu3 0
500 http://
100 /var/lib/