+2004-04-21 Marek Safar <marek.safar@seznam.cz>
+
+ * test-238.cs,
+ test-239.cs,
+ test-239.cs: Tests for ObsoleteAttribute
+
2004-04-21 Raja R Harinath <rharinath@novell.com>
* Makefile (test-compiler-jit-real): Create log files for failed
test-201 test-202 test-203 test-204 test-205 test-206 test-207 test-208 test-209 test-210 \
test-211 test-212 test-213 test-214 test-215 test-216 test-217 test-218 test-219 test-220 \
test-221 test-222 test-223 test-224 test-225 test-226 test-227 test-229 test-230 \
- test-231 test-232 test-233 test-234 test-235 test-236 test-237 \
+ test-231 test-232 test-233 test-234 test-235 test-236 test-237 test-238 test-239 \
cls-test-0 cls-test-1 cls-test-2 cls-test-3 cls-test-5 cls-test-6 cls-test-7 cls-test-10 \
cls-test-11 cls-test-14 cls-test-15 cls-test-16
* Attributes
- test-157.cs test-158.cs test-177.cs test-230.cs
+ test-157.cs test-158.cs test-177.cs test-230.cs test-238.cs test-239.cs test-240.cs
* Arrays and array creation
--- /dev/null
+using System;
+using System.Diagnostics;
+
+class TestClass {
+ [Conditional ("UNDEFINED CONDITION")]
+ static void ConditionalMethod ()
+ {
+ Environment.Exit (1);
+ }
+
+ static int Main()
+ {
+ ConditionalMethod ();
+ Console.WriteLine ("Succeeded");
+ return 0;
+ }
+}
--- /dev/null
+using System;
+using System.Diagnostics;
+
+
+class BaseClass
+{
+ [Conditional ("AAXXAA")]
+ public virtual void ConditionalMethod ()
+ {
+ Environment.Exit (1);
+ }
+}
+
+class TestClass: BaseClass
+{
+ public override void ConditionalMethod ()
+ {
+ base.ConditionalMethod ();
+ }
+}
+
+class MainClass
+{
+ static int Main()
+ {
+ TestClass ts = new TestClass ();
+ ts.ConditionalMethod ();
+ Console.WriteLine ("Succeeded");
+ return 0;
+ }
+}
--- /dev/null
+#define C2
+
+using System;
+using System.Diagnostics;
+
+class TestClass {
+
+ [Conditional("C1"), Conditional("C2")]
+ public static void ConditionalMethod()
+ {
+ Console.WriteLine ("Succeeded");
+ Environment.Exit (0);
+ }
+
+ static int Main()
+ {
+ ConditionalMethod ();
+ return 1;
+ }
+}