Summary: | Scrapbook page doesn't work with enhanced for statement | ||||||||
---|---|---|---|---|---|---|---|---|---|
Product: | [Eclipse Project] JDT | Reporter: | Olivier Thomann <Olivier_Thomann> | ||||||
Component: | Core | Assignee: | Olivier Thomann <Olivier_Thomann> | ||||||
Status: | VERIFIED FIXED | QA Contact: | |||||||
Severity: | normal | ||||||||
Priority: | P3 | CC: | philippe_mulet | ||||||
Version: | 3.1 | ||||||||
Target Milestone: | 3.1.1 | ||||||||
Hardware: | PC | ||||||||
OS: | Windows XP | ||||||||
Whiteboard: | |||||||||
Attachments: |
|
Description
Olivier Thomann
2005-07-05 15:40:46 EDT
Candidate for 3.1.1. The code snippet parser is missing the consumeEnhancedForStatement() method. If you remove the last line, you can execute the code. The fix is trivial. Adding this method in the code snippet parser fixes the problem. protected void consumeEnhancedForStatement() { super.consumeEnhancedForStatement(); /* recovery */ recordLastStatementIfNeeded(); } Created attachment 24361 [details]
Proposed fix
Created attachment 24363 [details]
Regression test
Agreed Fixed and released in 3.1 maintenance stream. Regression test added in org.eclipse.jdt.core.tests.eval.DebugEvaluationTest.test063 Verified with 3.2 M1 Verified using M20050923-1430 for 3.1.1 |