Bug 255974 - Abusive usage of InvalidInputException in the compiler
Summary: Abusive usage of InvalidInputException in the compiler
Status: VERIFIED FIXED
Alias: None
Product: JDT
Classification: Eclipse Project
Component: Core (show other bugs)
Version: 3.5   Edit
Hardware: PC Windows XP
: P3 normal (vote)
Target Milestone: 3.5 M4   Edit
Assignee: Olivier Thomann CLA
QA Contact:
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2008-11-20 09:30 EST by Olivier Thomann CLA
Modified: 2008-12-09 07:16 EST (History)
1 user (show)

See Also:


Attachments
Proposed fix (44.87 KB, patch)
2008-11-20 10:43 EST, Olivier Thomann CLA
no flags Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Olivier Thomann CLA 2008-11-20 09:30:52 EST
This exception should only be used in the context of the scanner.
It appears to be used in the configuration of the compiler when reading the classpath arguments.
In this context (batch compiler, compiler.apt and compiler.tool) we should use an IllegalArgumentException instead.
Comment 1 Olivier Thomann CLA 2008-11-20 10:43:39 EST
Created attachment 118371 [details]
Proposed fix
Comment 2 Olivier Thomann CLA 2008-11-20 10:43:56 EST
Jérôme, please review.
Comment 3 Olivier Thomann CLA 2008-11-20 10:57:13 EST
Released for 3.4M5.
To verify, the source code needs to be verified or do a search for InvalidInputException.
Comment 4 Jerome Lanneluc CLA 2008-11-20 11:14:01 EST
(In reply to comment #2)
> Jérôme, please review.
Looks good. I just removed an unused import, an unnecessary qualification to LIB, and ensured that the create jar was deleted in a finally in BatchCompilerTest.
Comment 5 Frederic Fusier CLA 2008-12-09 07:16:06 EST
Verified for 3.5M4 looking at references in 'thrown exceptions' in code of v_929.
Only found matches in Scanner or Parser hierarchy...