Fix 2.0 buglets exposed by the MOMA tool.
authorDuncan Mak <duncan@mono-cvs.ximian.com>
Wed, 29 Nov 2006 01:46:18 +0000 (01:46 -0000)
committerDuncan Mak <duncan@mono-cvs.ximian.com>
Wed, 29 Nov 2006 01:46:18 +0000 (01:46 -0000)
2006-11-28  Duncan Mak  <duncan@novell.com>

* TextReader.cs (Dispose): Expose as public in NET_2_0.

2006-11-28  Duncan Mak  <duncan@novell.com>

* ArgumentNullException.cs (.ctor): Added new constructor that's
new in .NET 2.0.

* InsufficientMemoryException.cs: Added missing 2.0 exception.

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

mcs/class/corlib/System.IO/ChangeLog
mcs/class/corlib/System.IO/TextReader.cs
mcs/class/corlib/System/ChangeLog
mcs/class/corlib/System/InsufficientMemoryException.cs [new file with mode: 0644]
mcs/class/corlib/corlib.dll.sources

index 8f9dad8045132437fcbdf0149e0ab5faf5e34d88..49b67f15e7d0ae78dfa43a99156eba24d21f3e71 100644 (file)
@@ -1,3 +1,7 @@
+2006-11-28  Duncan Mak  <duncan@novell.com>
+
+       * TextReader.cs (Dispose): Expose as public in NET_2_0.
+
 2006-11-26  Miguel de Icaza  <miguel@novell.com>
 
        * DriveInfo.cs, DriveType.cs: Add a couple of classes for
index 0ca3fd5574e4e3bd282f96f69bdbfcd314659833..cbc7c28e036605396c7d07ab68173b1cdd6f0bd5 100644 (file)
@@ -5,29 +5,29 @@
 //   Marcin Szczepanski (marcins@zipworld.com.au)\r
 //   Miguel de Icaza (miguel@gnome.org)\r
 //\r
-
-//
-// Copyright (C) 2004 Novell, Inc (http://www.novell.com)
-//
-// Permission is hereby granted, free of charge, to any person obtaining
-// a copy of this software and associated documentation files (the
-// "Software"), to deal in the Software without restriction, including
-// without limitation the rights to use, copy, modify, merge, publish,
-// distribute, sublicense, and/or sell copies of the Software, and to
-// permit persons to whom the Software is furnished to do so, subject to
-// the following conditions:
-// 
-// The above copyright notice and this permission notice shall be
-// included in all copies or substantial portions of the Software.
-// 
-// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
-// EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
-// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
-// NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
-// LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
-// OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
-// WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
-//
+\r
+//\r
+// Copyright (C) 2004 Novell, Inc (http://www.novell.com)\r
+//\r
+// Permission is hereby granted, free of charge, to any person obtaining\r
+// a copy of this software and associated documentation files (the\r
+// "Software"), to deal in the Software without restriction, including\r
+// without limitation the rights to use, copy, modify, merge, publish,\r
+// distribute, sublicense, and/or sell copies of the Software, and to\r
+// permit persons to whom the Software is furnished to do so, subject to\r
+// the following conditions:\r
+// \r
+// The above copyright notice and this permission notice shall be\r
+// included in all copies or substantial portions of the Software.\r
+// \r
+// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,\r
+// EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF\r
+// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND\r
+// NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE\r
+// LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION\r
+// OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION\r
+// WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.\r
+//\r
 \r
 using System;\r
 using System.Runtime.InteropServices;\r
@@ -46,7 +46,11 @@ namespace System.IO {
                        Dispose(true);\r
                }\r
 \r
+#if NET_2_0\r
+               public void Dispose ()\r
+#else\r
                void System.IDisposable.Dispose()\r
+#endif                 \r
                {\r
                        Dispose(true);\r
                }\r
@@ -66,7 +70,7 @@ namespace System.IO {
                        return -1;\r
                }\r
                \r
-
+\r
                public virtual int Read ([In, Out] char[] buffer, int index, int count)\r
                {\r
                        int c, i;\r
index 101d9ef234cc89c0b97906062694e01a0467c5ef..6156c6a56f145ee1ee6bbd861c7160290647fc5e 100644 (file)
@@ -1,3 +1,10 @@
+2006-11-28  Duncan Mak  <duncan@novell.com>
+
+       * ArgumentNullException.cs (.ctor): Added new constructor that's
+       new in .NET 2.0.
+
+       * InsufficientMemoryException.cs: Added missing 2.0 exception.
+       
 2006-11-27  Jonathan Chambers  <joncham@gmail.com>
 
        * __ComObject.cs: Removed IDispatchMono.
diff --git a/mcs/class/corlib/System/InsufficientMemoryException.cs b/mcs/class/corlib/System/InsufficientMemoryException.cs
new file mode 100644 (file)
index 0000000..f61b280
--- /dev/null
@@ -0,0 +1,52 @@
+//
+// InsufficientMemoryException.cs
+//
+// Author: Duncan Mak (duncan@novell.com)
+//
+// Copyright (C) 2006 Novell, Inc (http://www.novell.com)
+//
+// Permission is hereby granted, free of charge, to any person obtaining
+// a copy of this software and associated documentation files (the
+// "Software"), to deal in the Software without restriction, including
+// without limitation the rights to use, copy, modify, merge, publish,
+// distribute, sublicense, and/or sell copies of the Software, and to
+// permit persons to whom the Software is furnished to do so, subject to
+// the following conditions:
+// 
+// The above copyright notice and this permission notice shall be
+// included in all copies or substantial portions of the Software.
+// 
+// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
+// EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
+// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
+// NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
+// LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+// OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
+// WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
+//
+
+using System;
+
+#if NET_2_0
+namespace System {
+
+       [Serializable]
+       public sealed class InsufficientMemoryException : OutOfMemoryException
+       {
+               public InsufficientMemoryException ()
+               : base ("Insufficient memory")
+               {
+               }
+
+               public InsufficientMemoryException (string message)
+               : base (message)
+               {
+               }
+
+               public InsufficientMemoryException (string message, Exception base_exception)
+               : base (message, base_exception)
+               {
+               }
+       }
+}
+#endif
\ No newline at end of file
index ac34c5d90efb1e45d0b776beaffa955f60277ece..cab4e33d8e4f76e4cc0d4bba32d19580b0d27e22 100644 (file)
@@ -155,6 +155,7 @@ System/IDisposable.cs
 System/IFormatProvider.cs
 System/IFormattable.cs
 System/IndexOutOfRangeException.cs
+System/InsufficientMemoryException.cs
 System/Int16.cs
 System/Int32.cs
 System/Int64.cs