File:  [ELWIX - Embedded LightWeight unIX -] / embedaddon / php / tests / lang / 034.phpt
Revision 1.1.1.2 (vendor branch): download - view: text, annotated - select for diffs - revision graph
Mon Jul 22 01:32:14 2013 UTC (11 years, 3 months ago) by misho
Branches: php, MAIN
CVS tags: v5_4_29p0, v5_4_29, v5_4_20p0, v5_4_20, v5_4_17, HEAD
5.4.17

    1: --TEST--
    2: Bug #12647 (Locale settings affecting float parsing)
    3: --INI--
    4: precision=14
    5: --SKIPIF--
    6: <?php  # try to activate a german locale
    7: if (substr(PHP_OS, 0, 3) == 'WIN') {
    8:     /* skip on windows until #63688 was fixed */
    9:     die('skip');
   10: }
   11: if (setlocale(LC_NUMERIC, "de_DE.UTF-8", "de_DE", "de", "german", "ge", "de_DE.ISO-8859-1") === FALSE) {
   12: 	print "skip Can't find german locale";
   13: }
   14: ?>
   15: --FILE--
   16: <?php 
   17: # activate the german locale
   18: setlocale(LC_NUMERIC, "de_DE.UTF-8", "de_DE", "de", "german", "ge", "de_DE.ISO-8859-1");
   19: 
   20: echo (float)"3.14", "\n";
   21: ?>
   22: --EXPECT--
   23: 3,14

FreeBSD-CVSweb <freebsd-cvsweb@FreeBSD.org>