[Mono-bugs] [Bug 71576][Wis] Changed - ABCREM should obtain relationship info from % operators

bugzilla-daemon@bugzilla.ximian.com bugzilla-daemon@bugzilla.ximian.com
Fri, 21 Jan 2005 10:47:29 -0500 (EST)


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 bmaurer@users.sf.net.

http://bugzilla.ximian.com/show_bug.cgi?id=71576

--- shadow/71576	2005-01-21 10:31:19.000000000 -0500
+++ shadow/71576.tmp.30195	2005-01-21 10:47:29.000000000 -0500
@@ -1,14 +1,14 @@
 Bug#: 71576
 Product: Mono: Runtime
 Version: unspecified
-OS: 
+OS: unknown
 OS Details: 
 Status: NEW   
 Resolution: 
-Severity: 
+Severity: Unknown
 Priority: Wishlist
 Component: JIT
 AssignedTo: mono-bugs@ximian.com                            
 ReportedBy: vargaz@gmail.com               
 QAContact: mono-bugs@ximian.com
 TargetMilestone: ---
@@ -32,6 +32,24 @@
 }
 <<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<
 
 Here, the array bound check could be removed, since i % 10 is guaranteed 
 to be >=0 and < 10. This type of code is common in hashtables, like our
 own System.Collections.Hashtable:Find method ().
+
+------- Additional Comments From bmaurer@users.sf.net  2005-01-21 10:47 -------
+It is a bit harder than that:
+
+using System;
+
+class Tests
+{
+	public static void Main() {
+		int[] arr = new int [10];
+
+		int sum = 0;
+		for (int i = -100; i < 100; ++i)
+			sum += arr [i % 10];
+	}
+}
+
+Throws an exception.