Author: marek
Date: 2007-02-15 18:29:14 -0500 (Thu, 15 Feb 2007)
New Revision: 72973
Added:
trunk/mcs/errors/CS1681-2-lib.cs
trunk/mcs/errors/cs0152-2.cs
trunk/mcs/errors/cs1533.cs
trunk/mcs/errors/cs1681-2.cs
trunk/mcs/errors/gcs0453-5.cs
trunk/mcs/errors/gcs0721.cs
trunk/mcs/errors/gcs1100.cs
trunk/mcs/errors/gcs1101.cs
trunk/mcs/errors/gcs1102.cs
trunk/mcs/errors/gcs1103.cs
trunk/mcs/errors/gcs1104.cs
trunk/mcs/errors/gcs1105.cs
trunk/mcs/errors/gcs1106-2.cs
trunk/mcs/errors/gcs1106.cs
trunk/mcs/errors/gcs1109.cs
trunk/mcs/errors/gcs1110.cs
trunk/mcs/errors/gcs1112-2.cs
trunk/mcs/errors/gcs1112-3.cs
trunk/mcs/errors/gcs1112.cs
Modified:
trunk/mcs/errors/Makefile
trunk/mcs/errors/known-issues-gmcs
Log:
New tests.
Added: trunk/mcs/errors/CS1681-2-lib.cs
===================================================================
--- trunk/mcs/errors/CS1681-2-lib.cs 2007-02-15 23:25:35 UTC (rev 72972)
+++ trunk/mcs/errors/CS1681-2-lib.cs 2007-02-15 23:29:14 UTC (rev 72973)
@@ -0,0 +1,4 @@
+public class Test
+{
+}
+
Property changes on: trunk/mcs/errors/CS1681-2-lib.cs
___________________________________________________________________
Name: svn:eol-style
+ native
Modified: trunk/mcs/errors/Makefile
===================================================================
--- trunk/mcs/errors/Makefile 2007-02-15 23:25:35 UTC (rev 72972)
+++ trunk/mcs/errors/Makefile 2007-02-15 23:29:14 UTC (rev 72973)
@@ -11,7 +11,7 @@
MCS = $(with_mono_path) $(INTERNAL_MCS)
else
-EXTRA_SUPPORT_FILES = CSFriendAssembly-lib.dll GCS0730-lib.dll GCS0733-lib.dll
+EXTRA_SUPPORT_FILES = CSFriendAssembly-lib.dll GCS0121-2-lib.dll
GCS0730-lib.dll GCS0733-lib.dll
endif
ilasm = $(topdir)/class/lib/net_1_1_bootstrap/ilasm.exe
@@ -38,7 +38,8 @@
CS0433-lib.dll CS0433-2-lib.dll \
CS0534-3-lib.dll CS0534-4-lib.dll CS0571-3-lib.dll CS0571-5-lib.dll \
CS0612-2-lib.dll CS0618-2-lib.dll CS0619-8-lib.dll CS0619-17-lib.dll
CS0619-32-lib.dll CS0619-33-lib.dll CS0619-36-lib.dll CS0619-42-lib.dll \
- CS0619-43-lib.dll CS1546-lib.dll CS0619-51-lib.dll CS2015-lib.dll
CS3005-16-lib.dll CS3013-module.dll CSExternAlias-lib.dll \
+ CS0619-43-lib.dll CS1546-lib.dll CS0619-51-lib.dll CS1681-2-lib.dll \
+ CS2015-lib.dll CS3005-16-lib.dll CS3013-module.dll
CSExternAlias-lib.dll \
$(EXTRA_SUPPORT_FILES)
all-local:
Added: trunk/mcs/errors/cs0152-2.cs
===================================================================
--- trunk/mcs/errors/cs0152-2.cs 2007-02-15 23:25:35 UTC (rev 72972)
+++ trunk/mcs/errors/cs0152-2.cs 2007-02-15 23:29:14 UTC (rev 72973)
@@ -0,0 +1,23 @@
+// CS0152: The label `case E.Foo:' already occurs in this switch statement
+// Line: 19
+
+using System;
+
+enum E
+{
+ Foo = 2
+}
+
+class X
+{
+ void Foo (E e)
+ {
+ switch (e)
+ {
+ case E.Foo:
+ break;
+ case E.Foo:
+ break;
+ }
+ }
+}
Property changes on: trunk/mcs/errors/cs0152-2.cs
___________________________________________________________________
Name: svn:eol-style
+ native
Added: trunk/mcs/errors/cs1533.cs
===================================================================
--- trunk/mcs/errors/cs1533.cs 2007-02-15 23:25:35 UTC (rev 72972)
+++ trunk/mcs/errors/cs1533.cs 2007-02-15 23:29:14 UTC (rev 72973)
@@ -0,0 +1,17 @@
+// CS1533: Invoke cannot be called directly on a delegate
+// Line : 11
+// Compiler options: -langversion:ISO-1
+
+public class TestClass
+{
+ delegate void OneDelegate (int i);
+
+ static void Main()
+ {
+ OneDelegate d = new OneDelegate (TestMethod);
+ d.Invoke (1);
+ }
+ public static void TestMethod (int i)
+ {
+ }
+}
Property changes on: trunk/mcs/errors/cs1533.cs
___________________________________________________________________
Name: svn:eol-style
+ native
Added: trunk/mcs/errors/cs1681-2.cs
===================================================================
--- trunk/mcs/errors/cs1681-2.cs 2007-02-15 23:25:35 UTC (rev 72972)
+++ trunk/mcs/errors/cs1681-2.cs 2007-02-15 23:29:14 UTC (rev 72973)
@@ -0,0 +1,3 @@
+// CS1681: You cannot redefine the global extern alias
+// Line: 0
+// Compiler options: -r:global=CS1681-2-lib.dll
Added: trunk/mcs/errors/gcs0453-5.cs
===================================================================
--- trunk/mcs/errors/gcs0453-5.cs 2007-02-15 23:25:35 UTC (rev 72972)
+++ trunk/mcs/errors/gcs0453-5.cs 2007-02-15 23:29:14 UTC (rev 72973)
@@ -0,0 +1,24 @@
+// CS0453: The type `B.M' must be a non-nullable value type in order to use it
as type parameter `T' in the generic type or method `Foo.Test_2<T>(this T)'
+// Line: 20
+// Compiler options: -langversion:linq
+
+using System;
+
+public static class Foo
+{
+ public static string Test_2<T> (this T s) where T : struct
+ {
+ return null;
+ }
+}
+
+namespace B
+{
+ public class M
+ {
+ public static void Main ()
+ {
+ new M().Test_2();
+ }
+ }
+}
\ No newline at end of file
Property changes on: trunk/mcs/errors/gcs0453-5.cs
___________________________________________________________________
Name: svn:eol-style
+ native
Added: trunk/mcs/errors/gcs0721.cs
===================================================================
--- trunk/mcs/errors/gcs0721.cs 2007-02-15 23:25:35 UTC (rev 72972)
+++ trunk/mcs/errors/gcs0721.cs 2007-02-15 23:29:14 UTC (rev 72973)
@@ -0,0 +1,9 @@
+// CS0721: `C': static types cannot be used as parameters
+// Line: 6
+
+static class C
+{
+ static void Foo (this C c)
+ {
+ }
+}
\ No newline at end of file
Property changes on: trunk/mcs/errors/gcs0721.cs
___________________________________________________________________
Name: svn:eol-style
+ native
Added: trunk/mcs/errors/gcs1100.cs
===================================================================
--- trunk/mcs/errors/gcs1100.cs 2007-02-15 23:25:35 UTC (rev 72972)
+++ trunk/mcs/errors/gcs1100.cs 2007-02-15 23:29:14 UTC (rev 72973)
@@ -0,0 +1,9 @@
+// CS1100: The parameter modifier `this' can only be used on the first
parameter
+// Line: 6
+
+static class S
+{
+ static void Foo (bool b, this string s)
+ {
+ }
+}
\ No newline at end of file
Property changes on: trunk/mcs/errors/gcs1100.cs
___________________________________________________________________
Name: svn:eol-style
+ native
Added: trunk/mcs/errors/gcs1101.cs
===================================================================
--- trunk/mcs/errors/gcs1101.cs 2007-02-15 23:25:35 UTC (rev 72972)
+++ trunk/mcs/errors/gcs1101.cs 2007-02-15 23:29:14 UTC (rev 72973)
@@ -0,0 +1,9 @@
+// CS1101: The parameter modifiers `this' and `ref' cannot be used altogether
+// Line: 6
+
+static class S
+{
+ static void Foo (ref this string s)
+ {
+ }
+}
\ No newline at end of file
Property changes on: trunk/mcs/errors/gcs1101.cs
___________________________________________________________________
Name: svn:eol-style
+ native
Added: trunk/mcs/errors/gcs1102.cs
===================================================================
--- trunk/mcs/errors/gcs1102.cs 2007-02-15 23:25:35 UTC (rev 72972)
+++ trunk/mcs/errors/gcs1102.cs 2007-02-15 23:29:14 UTC (rev 72973)
@@ -0,0 +1,9 @@
+// CS1102: The parameter modifiers `this' and `out' cannot be used altogether
+// Line: 6
+
+static class S
+{
+ static void Foo (this out string s)
+ {
+ }
+}
\ No newline at end of file
Property changes on: trunk/mcs/errors/gcs1102.cs
___________________________________________________________________
Name: svn:eol-style
+ native
Added: trunk/mcs/errors/gcs1103.cs
===================================================================
--- trunk/mcs/errors/gcs1103.cs 2007-02-15 23:25:35 UTC (rev 72972)
+++ trunk/mcs/errors/gcs1103.cs 2007-02-15 23:29:14 UTC (rev 72973)
@@ -0,0 +1,10 @@
+// CS1103: The type of extension method cannot be `int*'
+// Line: 7
+// Compiler options: -unsafe
+
+static class S
+{
+ unsafe static void Foo (this int* iptr)
+ {
+ }
+}
\ No newline at end of file
Property changes on: trunk/mcs/errors/gcs1103.cs
___________________________________________________________________
Name: svn:eol-style
+ native
Added: trunk/mcs/errors/gcs1104.cs
===================================================================
--- trunk/mcs/errors/gcs1104.cs 2007-02-15 23:25:35 UTC (rev 72972)
+++ trunk/mcs/errors/gcs1104.cs 2007-02-15 23:29:14 UTC (rev 72973)
@@ -0,0 +1,9 @@
+// CS1104: The parameter modifiers `this' and `params' cannot be used
altogether
+// Line: 6
+
+static class S
+{
+ static void Foo (params this int[] o)
+ {
+ }
+}
\ No newline at end of file
Property changes on: trunk/mcs/errors/gcs1104.cs
___________________________________________________________________
Name: svn:eol-style
+ native
Added: trunk/mcs/errors/gcs1105.cs
===================================================================
--- trunk/mcs/errors/gcs1105.cs 2007-02-15 23:25:35 UTC (rev 72972)
+++ trunk/mcs/errors/gcs1105.cs 2007-02-15 23:29:14 UTC (rev 72973)
@@ -0,0 +1,9 @@
+// CS1105: `S.Foo(this int?)': Extension methods must be declared static
+// Line: 6
+
+static class S
+{
+ void Foo (this int? s)
+ {
+ }
+}
\ No newline at end of file
Property changes on: trunk/mcs/errors/gcs1105.cs
___________________________________________________________________
Name: svn:eol-style
+ native
Added: trunk/mcs/errors/gcs1106-2.cs
===================================================================
--- trunk/mcs/errors/gcs1106-2.cs 2007-02-15 23:25:35 UTC (rev 72972)
+++ trunk/mcs/errors/gcs1106-2.cs 2007-02-15 23:29:14 UTC (rev 72973)
@@ -0,0 +1,9 @@
+// CS1106: `S<T>.Foo(this string)': Extension methods must be defined in a
non-generic static class
+// Line: 6
+
+static class S<T>
+{
+ static void Foo (this string s)
+ {
+ }
+}
\ No newline at end of file
Property changes on: trunk/mcs/errors/gcs1106-2.cs
___________________________________________________________________
Name: svn:eol-style
+ native
Added: trunk/mcs/errors/gcs1106.cs
===================================================================
--- trunk/mcs/errors/gcs1106.cs 2007-02-15 23:25:35 UTC (rev 72972)
+++ trunk/mcs/errors/gcs1106.cs 2007-02-15 23:29:14 UTC (rev 72973)
@@ -0,0 +1,9 @@
+// CS1106: `S.Foo(this string)': Extension methods must be defined in a
non-generic static class
+// Line: 6
+
+class S
+{
+ static void Foo (this string s)
+ {
+ }
+}
\ No newline at end of file
Property changes on: trunk/mcs/errors/gcs1106.cs
___________________________________________________________________
Name: svn:eol-style
+ native
Added: trunk/mcs/errors/gcs1109.cs
===================================================================
--- trunk/mcs/errors/gcs1109.cs 2007-02-15 23:25:35 UTC (rev 72972)
+++ trunk/mcs/errors/gcs1109.cs 2007-02-15 23:29:14 UTC (rev 72973)
@@ -0,0 +1,12 @@
+// CS1109: `C.S.Foo(this string)': Extension methods cannot be defined in a
nested class
+// Line: 8
+
+class C
+{
+ static class S
+ {
+ static void Foo (this string s)
+ {
+ }
+ }
+}
\ No newline at end of file
Property changes on: trunk/mcs/errors/gcs1109.cs
___________________________________________________________________
Name: svn:eol-style
+ native
Added: trunk/mcs/errors/gcs1110.cs
===================================================================
--- trunk/mcs/errors/gcs1110.cs 2007-02-15 23:25:35 UTC (rev 72972)
+++ trunk/mcs/errors/gcs1110.cs 2007-02-15 23:29:14 UTC (rev 72973)
@@ -0,0 +1,10 @@
+// CS1110: `C.Foo(this string)': Extension methods cannot be declared without
a reference to System.Core.dll assembly. Add the assembly reference or remove
`this' modifer from the first parameter
+// Line: 7
+// Compiler options: -noconfig
+
+static class C
+{
+ static void Foo (this string s)
+ {
+ }
+}
\ No newline at end of file
Property changes on: trunk/mcs/errors/gcs1110.cs
___________________________________________________________________
Name: svn:eol-style
+ native
Added: trunk/mcs/errors/gcs1112-2.cs
===================================================================
--- trunk/mcs/errors/gcs1112-2.cs 2007-02-15 23:25:35 UTC (rev 72972)
+++ trunk/mcs/errors/gcs1112-2.cs 2007-02-15 23:29:14 UTC (rev 72973)
@@ -0,0 +1,21 @@
+// CS1112: Do not use `System.Runtime.CompilerServices.ExtensionAttribute'
directly. Use parameter modifier `this' instead
+// Line: 16
+// Compiler options: -langversion:linq
+
+using System;
+using System.Runtime.CompilerServices;
+
+namespace System.Runtime.CompilerServices
+{
+ public class ExtensionAttribute : Attribute
+ {
+ }
+}
+
+static class C
+{
+ [Extension]
+ static void Foo (this string s)
+ {
+ }
+}
\ No newline at end of file
Property changes on: trunk/mcs/errors/gcs1112-2.cs
___________________________________________________________________
Name: svn:eol-style
+ native
Added: trunk/mcs/errors/gcs1112-3.cs
===================================================================
--- trunk/mcs/errors/gcs1112-3.cs 2007-02-15 23:25:35 UTC (rev 72972)
+++ trunk/mcs/errors/gcs1112-3.cs 2007-02-15 23:29:14 UTC (rev 72973)
@@ -0,0 +1,7 @@
+// CS1112: Do not use `System.Runtime.CompilerServices.ExtensionAttribute'
directly. Use parameter modifier `this' instead
+// Line: 7
+// Compiler options: -langversion:linq
+
+using System.Runtime.CompilerServices;
+
+[assembly: ExtensionAttribute]
Property changes on: trunk/mcs/errors/gcs1112-3.cs
___________________________________________________________________
Name: svn:eol-style
+ native
Added: trunk/mcs/errors/gcs1112.cs
===================================================================
--- trunk/mcs/errors/gcs1112.cs 2007-02-15 23:25:35 UTC (rev 72972)
+++ trunk/mcs/errors/gcs1112.cs 2007-02-15 23:29:14 UTC (rev 72973)
@@ -0,0 +1,13 @@
+// CS1112: Do not use `System.Runtime.CompilerServices.ExtensionAttribute'
directly. Use parameter modifier `this' instead
+// Line: 8
+// Compiler options: -langversion:linq
+
+using System.Runtime.CompilerServices;
+
+static class C
+{
+ [Extension]
+ static void Foo (this string s)
+ {
+ }
+}
\ No newline at end of file
Property changes on: trunk/mcs/errors/gcs1112.cs
___________________________________________________________________
Name: svn:eol-style
+ native
Modified: trunk/mcs/errors/known-issues-gmcs
===================================================================
--- trunk/mcs/errors/known-issues-gmcs 2007-02-15 23:25:35 UTC (rev 72972)
+++ trunk/mcs/errors/known-issues-gmcs 2007-02-15 23:29:14 UTC (rev 72973)
@@ -37,6 +37,10 @@
cs0457-2.cs
cs0457.cs
-# Temporary stuff
-cs1107.cs
-cs1107-2.cs
\ No newline at end of file
+# Errors fixed in version 2.0 only
+cs1533.cs IGNORE
+
+#Temporary disabled
+gcs1112.cs
+gcs1112-2.cs
+gcs1112-3.cs
\ No newline at end of file
_______________________________________________
Mono-patches maillist - [email protected]
http://lists.ximian.com/mailman/listinfo/mono-patches