You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@commons.apache.org by Art Gramlich <ar...@gramlich-net.com> on 2005/02/21 05:16:38 UTC
[jci] Ignoring unused imports in the eclipse compiler
Here's a quick patch to make the eclipse compiler ignore unused
imports. I made it here locally since when testing "scripts", I
sometimes forget to clean up the imports. This seems to help.
Art Gramlich
Index: EclipseJavaCompiler.java
===================================================================
---
src/java/org/apache/commons/jci/compilers/eclipse/
EclipseJavaCompiler.java (revision 154619)
+++
src/java/org/apache/commons/jci/compilers/eclipse/
EclipseJavaCompiler.java (working copy)
@@ -113,6 +113,7 @@
settings.put(CompilerOptions.OPTION_LineNumberAttribute,
CompilerOptions.GENERATE);
settings.put(CompilerOptions.OPTION_SourceFileAttribute,
CompilerOptions.GENERATE);
settings.put(CompilerOptions.OPTION_ReportDeprecation,
CompilerOptions.IGNORE);
+ settings.put(CompilerOptions.OPTION_ReportUnusedImport,
CompilerOptions.IGNORE);
settings.put(CompilerOptions.OPTION_Encoding, "UTF-8");
settings.put(CompilerOptions.OPTION_LocalVariableAttribute,
CompilerOptions.GENERATE);
settings.put(CompilerOptions.OPTION_Source,
CompilerOptions.VERSION_1_4);
---------------------------------------------------------------------
To unsubscribe, e-mail: commons-dev-unsubscribe@jakarta.apache.org
For additional commands, e-mail: commons-dev-help@jakarta.apache.org
Re: [jci] Ignoring unused imports in the eclipse compiler
Posted by Torsten Curdt <tc...@apache.org>.
...makes sense
> Here's a quick patch to make the eclipse compiler ignore unused
> imports. I made it here locally since when testing "scripts", I
> sometimes forget to clean up the imports. This seems to help.
Thanks
--
Torsten