[Numpy-svn] r6302 - trunk/numpy/core/tests

numpy-svn@scip... numpy-svn@scip...
Thu Jan 8 09:11:35 CST 2009


Author: cdavid
Date: 2009-01-08 09:11:32 -0600 (Thu, 08 Jan 2009)
New Revision: 6302

Modified:
   trunk/numpy/core/tests/test_print.py
Log:
Fix python 2.4 issue.

Modified: trunk/numpy/core/tests/test_print.py
===================================================================
--- trunk/numpy/core/tests/test_print.py	2009-01-08 09:19:00 UTC (rev 6301)
+++ trunk/numpy/core/tests/test_print.py	2009-01-08 15:11:32 UTC (rev 6302)
@@ -128,14 +128,15 @@
 def has_french_locale():
     curloc = locale.getlocale(locale.LC_NUMERIC)
     try:
-        if not sys.platform == 'win32':
-            locale.setlocale(locale.LC_NUMERIC, 'fr_FR')
-        else:
-            locale.setlocale(locale.LC_NUMERIC, 'FRENCH')
+        try:
+            if not sys.platform == 'win32':
+                locale.setlocale(locale.LC_NUMERIC, 'fr_FR')
+            else:
+                locale.setlocale(locale.LC_NUMERIC, 'FRENCH')
 
-        st = True
-    except:
-        st = False
+            st = True
+        except:
+            st = False
     finally:
         locale.setlocale(locale.LC_NUMERIC, locale=curloc)
 



More information about the Numpy-svn mailing list