2002-04-10 Gonzalo Paniagua Javier <gonzalo@ximian.com>
authorGonzalo Paniagua Javier <gonzalo.mono@gmail.com>
Wed, 10 Apr 2002 11:11:31 +0000 (11:11 -0000)
committerGonzalo Paniagua Javier <gonzalo.mono@gmail.com>
Wed, 10 Apr 2002 11:11:31 +0000 (11:11 -0000)
* Int32.cs:
* UInt32.cs:
* Int64.cs:
* UInt64.cs: changed Type.GetType () by typeof (), as suggested by
lupus.

* Int32.cs:
* Int64.cs: throw an OverFlowException when parsing a string
containing a dot followed by any non '0' number.

svn path=/trunk/mcs/; revision=3737

mcs/class/corlib/System/ChangeLog
mcs/class/corlib/System/Int32.cs
mcs/class/corlib/System/Int64.cs
mcs/class/corlib/System/UInt32.cs
mcs/class/corlib/System/UInt64.cs

index f02a5cf073986eb6073ee37c8872ed8b214504ed..544a3677f57fb65b76bd3c151c8dbe697667af72 100644 (file)
@@ -1,3 +1,15 @@
+2002-04-10  Gonzalo Paniagua Javier <gonzalo@ximian.com>
+
+       * Int32.cs:
+       * UInt32.cs:
+       * Int64.cs: 
+       * UInt64.cs: changed Type.GetType () by typeof (), as suggested by
+       lupus.
+
+       * Int32.cs:
+       * Int64.cs: throw an OverFlowException when parsing a string 
+       containing a dot followed by any non '0' number.
+
 2002-04-10  Gonzalo Paniagua Javier <gonzalo@ximian.com>
 
        * Byte.cs:
index e04679b4e6ac39152084ef8ecdf1ce26dd0e1ef6..acf11dbb1e52fc3c371ae1483598376a366d602d 100644 (file)
@@ -190,7 +190,7 @@ namespace System {
 
                        NumberFormatInfo nfi;
                        if (fp != null) {
-                               Type typeNFI = Type.GetType ("System.Globalization.NumberFormatInfo");
+                               Type typeNFI = typeof (System.Globalization.NumberFormatInfo);
                                nfi = (NumberFormatInfo) fp.GetFormat (typeNFI);
                        }
                        else
@@ -313,8 +313,8 @@ namespace System {
                                        // Allows decimal point as long as it's only 
                                        // followed by zeroes.
                                        if (s [pos++] != '0')
-                                               throw new FormatException ("Input string was not in the " + 
-                                                                          "correct format.");
+                                               throw new OverflowException ("Value too large or too " +
+                                                                            "small.");
                                }
                                else {
                                        nDigits++;
index 962a1503689bb23d546e8d65ae3eed2b665242b9..8cda8659bb323eb2243c90bcd9fa00a58bfeb3ce 100644 (file)
@@ -191,7 +191,7 @@ namespace System {
 
                        NumberFormatInfo nfi;
                        if (fp != null) {
-                               Type typeNFI = Type.GetType ("System.Globalization.NumberFormatInfo");
+                               Type typeNFI = typeof (System.Globalization.NumberFormatInfo);
                                nfi = (NumberFormatInfo) fp.GetFormat (typeNFI);
                        }
                        else
@@ -314,8 +314,8 @@ namespace System {
                                        // Allows decimal point as long as it's only 
                                        // followed by zeroes.
                                        if (s [pos++] != '0')
-                                               throw new FormatException ("Input string was not in the " + 
-                                                                          "correct format.");
+                                               throw new OverflowException ("Value too large or too " +
+                                                                            "small.");
                                }
                                else {
                                        nDigits++;
index 4bd351305dfacaa259b061e6dcc4c6d6b7d8afc2..0ce3bfd3de18b2a59a2ee9ca5b048c8f57e018b2 100644 (file)
@@ -192,7 +192,7 @@ namespace System {
 
                        NumberFormatInfo nfi;
                        if (fp != null) {
-                               Type typeNFI = Type.GetType ("System.Globalization.NumberFormatInfo");
+                               Type typeNFI = typeof (System.Globalization.NumberFormatInfo);
                                nfi = (NumberFormatInfo) fp.GetFormat (typeNFI);
                        }
                        else
index 6efaba5b90f0569ded48aa2b2b8381a381055472..25585a3df499d3098a72947c9190f8d65ca49f4e 100644 (file)
@@ -145,7 +145,7 @@ namespace System {
 
                        NumberFormatInfo nfi;
                        if (fp != null) {
-                               Type typeNFI = Type.GetType ("System.Globalization.NumberFormatInfo");
+                               Type typeNFI = typeof (System.Globalization.NumberFormatInfo);
                                nfi = (NumberFormatInfo) fp.GetFormat (typeNFI);
                        }
                        else