Signed-off-by: Tomek Grabiec <[email protected]>
---
regression/jvm/ObjectStackTest.java | 19 +++++++++++++++++++
1 files changed, 19 insertions(+), 0 deletions(-)
diff --git a/regression/jvm/ObjectStackTest.java
b/regression/jvm/ObjectStackTest.java
index 7e6a2b8..bafb120 100644
--- a/regression/jvm/ObjectStackTest.java
+++ b/regression/jvm/ObjectStackTest.java
@@ -58,9 +58,28 @@ public class ObjectStackTest extends TestCase {
assertEquals(0, x++);
}
+
+ public static int classField;
+
+ public static void testLoadAndIncrementClassField() {
+ classField = 0;
+ assertEquals(0, classField++);
+ }
+
+ public int instanceField;
+
+ public static void testLoadAndIncrementInstanceField() {
+ ObjectStackTest test = new ObjectStackTest();
+
+ test.instanceField = 0;
+ assertEquals(0, test.instanceField++);
+ }
+
public static void main(String[] args) {
testObjectStackWhenBranching();
testLoadAndIncrementLocal();
+ testLoadAndIncrementClassField();
+ testLoadAndIncrementInstanceField();
exit();
}
--
1.6.0.6
------------------------------------------------------------------------------
_______________________________________________
Jatovm-devel mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/jatovm-devel