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>2010-11-10 17:18:34 +0300
committerMarek Safar <marek.safar@gmail.com>2010-11-10 20:57:08 +0300
commitbdf6dee0fac9de8c9032deed0111d6bd238f298b (patch)
tree64c4da36dbb7e9d299a23884905402f0c6384bb5 /mcs/tests/test-783.cs
parente02fd2fdd6fa5a5d629020c522f08a6b0edfa209 (diff)
More tweaks for nullable binary operation
Diffstat (limited to 'mcs/tests/test-783.cs')
-rw-r--r--mcs/tests/test-783.cs35
1 files changed, 30 insertions, 5 deletions
diff --git a/mcs/tests/test-783.cs b/mcs/tests/test-783.cs
index a9756d8550a..93e24821d8b 100644
--- a/mcs/tests/test-783.cs
+++ b/mcs/tests/test-783.cs
@@ -2,15 +2,40 @@ enum E { a, b }
class C
{
- public static void Main ()
+ static void M (E e)
+ {
+ }
+
+ static int Test (int a)
+ {
+ return -1;
+ }
+
+ static int Test (E e)
+ {
+ return 1;
+ }
+
+ public static int Main ()
{
M ((uint) 0);
M ((long) 0);
M ((sbyte) 0);
M ((ulong) 0);
- }
+
+ var d = E.b;
+ if (Test (d - 0) != 1)
+ return 1;
+
+ if (Test (d - 1) != 1)
+ return 2;
- static void M (E e)
- {
+ if (Test (d + 0) != 1)
+ return 3;
+
+ if (Test (d + 1) != 1)
+ return 4;
+
+ return 0;
}
-} \ No newline at end of file
+}