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>2013-10-10 18:05:59 +0400
committerMarek Safar <marek.safar@gmail.com>2013-10-10 18:09:31 +0400
commita55758d13614755cc875446f5039daa9e725d4f3 (patch)
treeb05e3853cf4996b9d2f71fb82246f21ff57d466e /mcs/tests/test-870.cs
parent87d6328f2fa219d97ee95a529cd4cfe29f9a64cf (diff)
Compound assignment of optimized binary constant needs to decompose it first. Fixes #15315
Diffstat (limited to 'mcs/tests/test-870.cs')
-rw-r--r--mcs/tests/test-870.cs17
1 files changed, 17 insertions, 0 deletions
diff --git a/mcs/tests/test-870.cs b/mcs/tests/test-870.cs
new file mode 100644
index 00000000000..5faceb7b35a
--- /dev/null
+++ b/mcs/tests/test-870.cs
@@ -0,0 +1,17 @@
+public class Test
+{
+ static void Foo (ushort p)
+ {
+ p = 0x0000;
+ p |= 0x0000;
+ p &= 0x0000;
+
+ const ushort c = 0x0000;
+ p &= c;
+ }
+
+ public static void Main ()
+ {
+ Foo (1);
+ }
+} \ No newline at end of file