[Mono-bugs] [Bug 80206][Nor] New - Using a List<byte> item with compound assigment operators fails to compile
bugzilla-daemon at bugzilla.ximian.com
bugzilla-daemon at bugzilla.ximian.com
Sat Dec 9 12:37:28 EST 2006
Please do not reply to this email- if you want to comment on the bug, go to the
URL shown below and enter your comments there.
Changed by mgreger at cinci.rr.com.
http://bugzilla.ximian.com/show_bug.cgi?id=80206
--- shadow/80206 2006-12-09 12:37:28.000000000 -0500
+++ shadow/80206.tmp.14038 2006-12-09 12:37:28.000000000 -0500
@@ -0,0 +1,71 @@
+Bug#: 80206
+Product: Mono: Compilers
+Version: 1.2
+OS:
+OS Details: Windows XP SP2
+Status: NEW
+Resolution:
+Severity:
+Priority: Normal
+Component: C#
+AssignedTo: rharinath at novell.com
+ReportedBy: mgreger at cinci.rr.com
+QAContact: mono-bugs at ximian.com
+TargetMilestone: ---
+URL:
+Cc:
+Summary: Using a List<byte> item with compound assigment operators fails to compile
+
+Please fill in this template when reporting a bug, unless you know what
+you are doing.
+Description of Problem:
+
+
+The following code will not compile under Mono 1.2.2.1 but will under
+Visual Studio 2005. All eight compound assigments are flagged as errors.
+
+using System;
+using System.Collections.Generic;
+
+namespace Test
+{
+ class Program
+ {
+ static void Main(string[] args)
+ {
+ List<byte> aList = new List<byte>();
+ aList.Add(1);
+ byte x = 1;
+ aList[0] += x;
+ aList[0] -= x;
+ aList[0] *= x;
+ aList[0] /= x;
+ aList[0] %= x;
+ aList[0] &= x;
+ aList[0] |= x;
+ aList[0] ^= x;
+ }
+ }
+}
+
+
+Steps to reproduce the problem:
+1. Try to compile using gmcs.
+2.
+3.
+
+Actual Results:
+
+Will not compile. All compound assigments to a List<byte> item are
+flagged as errors.
+
+Expected Results:
+
+This does compile under Visual Studio 2005. Replacing the List<byte> item
+with a byte variable compiles under Mono.
+
+How often does this happen?
+
+Always
+
+Additional Information:
More information about the mono-bugs
mailing list