Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.
Bug 348369 - [1.7] Missing error "No exception of type Exception[] can be thrown"
Summary: [1.7] Missing error "No exception of type Exception[] can be thrown"
Status: VERIFIED FIXED
Alias: None
Product: JDT
Classification: Eclipse Project
Component: Core (show other bugs)
Version: 3.7   Edit
Hardware: PC Windows XP
: P3 normal (vote)
Target Milestone: 3.7.1   Edit
Assignee: Srikanth Sankaran CLA
QA Contact:
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2011-06-06 05:19 EDT by Deepak Azad CLA
Modified: 2011-08-05 02:54 EDT (History)
3 users (show)

See Also:


Attachments
Patch v0.99 (4.02 KB, patch)
2011-06-06 07:06 EDT, Srikanth Sankaran CLA
no flags Details | Diff
Proposed patch + tests (4.07 KB, patch)
2011-06-06 10:37 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 Deepak Azad CLA 2011-06-06 05:19:14 EDT
BETA_JAVA7

The compiler does not show any error in the following snippet.
---------------------------------
try {
	System.out.println();
} catch (Exception e []) { 
	e.printStackTrace();
} 
---------------------------------

but shows an error for the following
---------------------------------
try {
	System.out.println();
} catch (Exception [] e) { 
	e.printStackTrace();
} 
---------------------------------

Both snippets result in an error with HEAD
Comment 1 Srikanth Sankaran CLA 2011-06-06 05:28:48 EDT
I'll take a look,
Comment 2 Srikanth Sankaran CLA 2011-06-06 07:06:06 EDT
Created attachment 197385 [details]
Patch v0.99

This fixes the problem and includes tests.

There is still some issue with source positions.
Comment 3 Srikanth Sankaran CLA 2011-06-06 10:37:10 EDT
Created attachment 197397 [details]
Proposed patch + tests
Comment 4 Srikanth Sankaran CLA 2011-06-06 13:20:36 EDT
Thanks for the report, fix & tests released in BETA_JAVA 7 branch.
Comment 5 Satyam Kandula CLA 2011-07-01 01:08:58 EDT
Verified using Eclipse Java 7 Support(Beta) feature patch v20110623-0900.