Community
Participate
Working Groups
Problem occurs during "running" of a Java application: java.lang.VerifyError: (class: com/quickbusiness/courier/Class2, method: run signature: ()V) Expecting to find long on stack Exception in thread "main" I *think* I've narrowed it down to this line in the code... Thread.sleep(interval = interval + 100); I've created a dummy class which exhibits this problem. I'll try to attach that Class as a seperate file. PS: I don't claim to be the worlds greatest programmer so go easy on me please :)
Created attachment 20653 [details] Sample code which exhibits problem behaviour
Problem is also occuring identically on Mac Powerbook G4
Confirmed - I changed this line in my "real" code and things now run under Eclipse. Old: Thread.sleep(interval = interval + 100); New: interval = interval + 100; Thread.sleep(interval); Yet the "old" code both compiles and runs under the "same" jar in Windows and Mac when I run from the command line.
Moving to JDT Core...
Reproduced in 3.1 stream as well.
Also note that: Thread.sleep(interval += 100); would work fine. Somehow one bytecode generation is losing the conversion from int to long, when optimizing "interval = interval + 100" into "interval += 100".
Optimized code gen was missing extra implicit conversion on SingleNameReference. Also fixed eval side. Added AssignmentTest#test037. Fixed
Verified in I20050510-0010 + JDT/Core from HEAD.