[Mono-bugs] [Bug 61801][Wis] Changed - Incorrect exception ordering with stelem
bugzilla-daemon@bugzilla.ximian.com
bugzilla-daemon@bugzilla.ximian.com
Wed, 21 Jul 2004 16:42:06 -0400 (EDT)
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=61801
--- shadow/61801 2004-07-21 16:29:40.000000000 -0400
+++ shadow/61801.tmp.27497 2004-07-21 16:42:06.000000000 -0400
@@ -51,6 +51,24 @@
public int x;
}
This program shold throw division by 0 but throws a nullref. Note that
we get away with some problems because we end up emitting a mov DWORD
PTR [0], result
+
+------- Additional Comments From bmaurer@users.sf.net 2004-07-21 16:42 -------
+In fact, this problem is more widespread than just stores:
+
+class T {
+ static T t;
+ T x;
+ static int foo;
+ static void Main () {
+ t.x.Foo (foo / 0);
+ }
+
+ void Foo (int x) {}
+}
+
+In short, the problem seems to be that the way our code is emitted,
+things do not happen in the order they should. For example, here, the
+access to t.x should happen before the evaluation of foo / 0.