From: [EMAIL PROTECTED] Operating system: PHP version: 4.1.1 PHP Bug Type: Feature/Change Request Bug description: more variable type should be added
php class has no `operator` behave like c++ so, it's quite different between user-defined-object and internal-variable-type i suggest that wide-string type should be added. which behave like wchar_t in vc, but more powerful wide-string is not that mbstring mbstring is an extension not internal type every char of wide-string is wide-char(wchar), both ascii and multibyte-char there's also a bunch of wide-string operating function in i18n mbstring is so complexity that use more cpu-time wide-string take more memory but simple to process samples: $str = "string"; // This is a normal string $wstr = L"string"; // This is a wide-string echo strlen($str); // 6 echo strlen($wstr); // also 6 echo memsize($wstr); // 6 echo memsize($wstr); // 12 echo $str == $wstr; // true echo $str === $wstr; // false "\x20"; // normal string L"\x20"; // wide-string L"\x4c3a"; // wide-string and echo preg_replace(L"/abc/", "def", "abcdef"); should also works for matching wide-string if (strpos(L"abc", L"def") === false) .....; see? quite different from "mbstring" but.. if adding wchar_t support to every string function make it slower, i'd like to have a set of "w" prefix functions such as wstrcmp wstrpos wpreg_replace not "mb" :p if php preferer mbstring rather than wchar_t at least, make mbstring internal, not as extension. when compiled without mbstring, all mbstring-type is processed exactly like normal string. that's all -- Edit bug report at http://bugs.php.net/?id=15689&edit=1 -- Fixed in CVS: http://bugs.php.net/fix.php?id=15689&r=fixedcvs Fixed in release: http://bugs.php.net/fix.php?id=15689&r=alreadyfixed Need backtrace: http://bugs.php.net/fix.php?id=15689&r=needtrace Try newer version: http://bugs.php.net/fix.php?id=15689&r=oldversion Not developer issue: http://bugs.php.net/fix.php?id=15689&r=support Expected behavior: http://bugs.php.net/fix.php?id=15689&r=notwrong Not enough info: http://bugs.php.net/fix.php?id=15689&r=notenoughinfo Submitted twice: http://bugs.php.net/fix.php?id=15689&r=submittedtwice