Bug 83478

Summary: VerifyError thrown when void return used. 3.1M4
Product: [Eclipse Project] JDT Reporter: Keith Whittingham <kwhittingham>
Component: CoreAssignee: JDT-Core-Inbox <jdt-core-inbox>
Status: RESOLVED DUPLICATE QA Contact:
Severity: normal    
Priority: P3    
Version: 3.1   
Target Milestone: 3.1 M5   
Hardware: PC   
OS: Windows XP   
Whiteboard:

Description Keith Whittingham CLA 2005-01-22 11:29:23 EST
Hi guys,

I got a...

Exception in thread "main" java.lang.VerifyError: (class: com/inexas/eiap/page/
PageParserImpl, method: terminate signature: (I)V) Unable to pop operand off an 
empty stack
	at java.lang.Class.forName0(Native Method)
	at java.lang.Class.forName(Class.java:164)
	at com.inexas.eiap.page.BuildTestPageParser.main(BuildTestPageParser.java:22)

The reason was because I had a line of code which read

   textBuilder.append(currentWord.terminate());

where the terminate() method returns void....

   void terminate()

The compiler missed the error (so did I!!!!). It was in a switch statement
if that makes any difference.

Keep up the good work - great stuff!!!
Comment 1 Philipe Mulet CLA 2005-01-23 06:50:44 EST

*** This bug has been marked as a duplicate of 81971 ***