Bug 212713 - Bad error message for static block inside an interface
Summary: Bad error message for static block inside an interface
Status: VERIFIED FIXED
Alias: None
Product: JDT
Classification: Eclipse Project
Component: Core (show other bugs)
Version: 3.3   Edit
Hardware: PC Windows XP
: P3 normal (vote)
Target Milestone: 3.7 M1   Edit
Assignee: Srikanth Sankaran CLA
QA Contact:
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2007-12-12 01:13 EST by Mohsen Saboorian CLA
Modified: 2010-08-03 09:26 EDT (History)
4 users (show)

See Also:


Attachments
Patch under consideration (95.89 KB, patch)
2010-07-06 04:03 EDT, Srikanth Sankaran CLA
no flags Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Mohsen Saboorian CLA 2007-12-12 01:13:27 EST
1. create an interface
2. put a static block inside it
3. see the error message:
	Syntax error, insert "enum Identifier" to complete EnumHeader
Comment 1 Philipe Mulet CLA 2007-12-12 07:12:40 EST
Wondering if we shouldn't be more permissive in our grammar and tolerate static initializers early on, so we can reject them later on; without doing fancy recovery on curly braces.
Comment 2 Srikanth Sankaran CLA 2010-07-06 04:03:17 EDT
Created attachment 173509 [details]
Patch under consideration
Comment 3 Srikanth Sankaran CLA 2010-07-06 04:43:44 EDT
All tests pass, Ayush please review, Thanks in advance.
Comment 4 Ayushman Jain CLA 2010-07-07 01:46:14 EDT
Patch looks good.
Comment 5 Srikanth Sankaran CLA 2010-07-07 01:59:28 EDT
Released in HEAD for 3.7 M1
Comment 6 Ayushman Jain CLA 2010-08-03 09:26:31 EDT
Verified for 3.7M1 using build I20100802-1800.