diff -r 2763b87dd7e8 -r 8eaaeb6ed8f3 numpy/lib/npyio.py
--- a/numpy/lib/npyio.py	Fri Mar 25 22:37:19 2011 -0600
+++ b/numpy/lib/npyio.py	Sat Mar 26 12:40:26 2011 +0100
@@ -566,7 +566,20 @@
     if issubclass(typ, np.bool_):
         return lambda x: bool(int(x))
     if issubclass(typ, np.integer):
-        return lambda x: int(float(x))
+        def _intconv(x):
+            try:
+                # This works for long integer, for example:
+                # >>> int('123456789123456789123456789123456789')
+                # 123456789123456789123456789123456789L
+                
+                y = int(x)
+            except ValueError:
+                # This will work if the number is a float, for example:
+                # >>> int(float('1.23e45'))
+                # 1229999999999999973814869011019624571608236032L
+                y = int(float(x))
+            return y
+        return _intconv
     elif issubclass(typ, np.floating):
         return float
     elif issubclass(typ, np.complex):
