This Bugzilla instance is a read-only archive of historic NetBeans bug reports. To report a bug in NetBeans please follow the project's instructions for reporting issues.
Consider the code: int i=0; for (int j=0; j < 100; j++) { System.out.println(i); } Put breakpoint onto line with System.out... and debug the code. 0 is written in output, try continue action several times just to be sure. Now create new watch with watch expression i++. Invoke continue -> 3 is written into output. Next continue -> 6 is written... 9, 11, 13, 15. Also the number of evaluations changes! In NB3.6 it produced 0,0...,0,1,2,3... as output.
This has been fixed already. There is a minor change in the new expression evaluator: ++,-- and assignment operators never change values of their operand variables during watch evaluation.
Verified on build 200407201800
It is there again, but in some other scenario. Consider code for (int i=0; i<10; i++) { hmap.put(""+i, i+".item"); } Put breakpoint somwhere after the code and make debugger to hit it. Now create watch with expression hmap.put("6", "test") => the watch has value "test", which means it was evaluated more than once (first evaluation would return "6.item" and it works in NB3.6)
fixed in trunk
Verified in 4.2 build 200507061800