Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/mono/mono.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMiguel de Icaza <miguel@gnome.org>2003-02-26 05:13:30 +0300
committerMiguel de Icaza <miguel@gnome.org>2003-02-26 05:13:30 +0300
commita74e0bd2c686159a5a32579b5000a1cb062591a1 (patch)
tree4c7eb00c31d83be5805506c67e0ea0fb9d52dbe7 /mcs/tests/test-187.cs
parentcbe579519f2d9bd589124066d6ac1400bbe8f1f0 (diff)
Improve test
svn path=/trunk/mcs/; revision=11975
Diffstat (limited to 'mcs/tests/test-187.cs')
-rw-r--r--mcs/tests/test-187.cs33
1 files changed, 32 insertions, 1 deletions
diff --git a/mcs/tests/test-187.cs b/mcs/tests/test-187.cs
index b85a66a6700..ece3a82d4ef 100644
--- a/mcs/tests/test-187.cs
+++ b/mcs/tests/test-187.cs
@@ -2,15 +2,46 @@
// This test verifies that we resolve the source expression in a compound
// expression before we attempt to use it.
//
+// The test also attempts
+//
using System.Collections.Specialized;
+public class MyClass
+{
+ public Container this [ string s ]
+ {
+ get { return null; }
+ set { ; }
+ }
+}
+
+
+public class Container
+{
+ public static Container operator + ( Container c, object o )
+ {
+ return c;
+ }
+}
+
class D {
- static void A (NameValueCollection n)
+ static void A (NameValueCollection n, MyClass m, object o)
{
+ //
+ // Tests that ";" is a StringLiteral, *and* it has been resolved. Triggered
+ // by indexers, as indexers trigger an OverloadResolve.
+ //
n ["a"] += ";";
+
+ //
+ // A different, but similar beast. A bug existed in the compiler that
+ // prevented the following from working (bug 36505)
+ //
+ m["apple"] += o;
}
+
static int Main ()
{
return 0;