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:
authorMarek Safar <marek.safar@gmail.com>2008-05-01 12:57:01 +0400
committerMarek Safar <marek.safar@gmail.com>2008-05-01 12:57:01 +0400
commitbdc31622ece4232e2f18a0c4cf72093032988604 (patch)
treed0784d9a4441feac7d05e6f5d462a4510040c041 /mcs/tests/test-641.cs
parent169f8e7ccc34039321eb99cec18cb745e76133fc (diff)
New test.
svn path=/trunk/mcs/; revision=102263
Diffstat (limited to 'mcs/tests/test-641.cs')
-rw-r--r--mcs/tests/test-641.cs46
1 files changed, 46 insertions, 0 deletions
diff --git a/mcs/tests/test-641.cs b/mcs/tests/test-641.cs
new file mode 100644
index 00000000000..c128d5eca75
--- /dev/null
+++ b/mcs/tests/test-641.cs
@@ -0,0 +1,46 @@
+using System;
+
+public class Identifier
+{
+ public Identifier () { }
+
+ public static bool operator == (Identifier id1, Identifier id2)
+ {
+ return true;
+ }
+ public static bool operator != (Identifier id1, Identifier id2)
+ {
+ return true;
+ }
+
+ public static implicit operator Identifier (string identifier)
+ {
+ return null;
+ }
+
+ public static implicit operator String (Identifier id)
+ {
+ return null;
+ }
+
+ public static implicit operator decimal (Identifier id)
+ {
+ return -1;
+ }
+
+ static int Main ()
+ {
+ Identifier a = null;
+ string b = "a";
+
+ if (!(a == b))
+ return 1;
+
+ decimal d = 5;
+ if (a == d)
+ return 2;
+
+ return 0;
+ }
+}
+