INRIA / INRIA/spoon

OutputType Filter not implemented for Compilation Unit output type

Open
#4,270 0 comments 0 reactions 0 assignees View on GitHub
Dominant language
Java
Stars
2k
Forks
392
Avg merge
11h 24m
Merged PRs (30d)
36

Description

As per the code snippet from JDTBasedSpoonCompiler, the output type filter is not considered for compilation unit. For the sniper mode printing , the output type is internally configured as compilation unit. I am using a maven project with Maven Launcher and only interested in outputing the modified compilation unit to the ouput folder. Currently , all the input files are populated in the ouput folder too which is not correct.
`@Override
public void generateProcessedSourceFiles(OutputType outputType, Filter> typeFilter) {
getEnvironment().getSpoonProgress().start(SpoonProgress.Process.PRINT);
switch (outputType) {
case CLASSES:
generateProcessedSourceFilesUsingTypes(typeFilter);
break;
case COMPILATION_UNITS:
generateProcessedSourceFilesUsingCUs();
break;
case NO_OUTPUT:
}
getEnvironment().getSpoonProgress().end(SpoonProgress.Process.PRINT);
}`

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.