Skip to content

Conversation

@big-andy-coates
Copy link
Collaborator

@big-andy-coates big-andy-coates commented Jul 22, 2022

fixes: #211

Avoids ``--add-opens has no effect at compile timewarnings when compiling test code by filtering out--add-opens` entries from the `module-info.test` file when executing the `compileTestJava` task.

This is achieved by filtering out any --add-opens lines and the subsequent line, which contains the opens to add, in the ModuleInfoTestHelper class.

fixes: java9-modularity#211

Avoids ``--add-opens has no effect at compile time` warnings when compiling test code by filtering out
`--add-opens` entries from the `module-info.test` file when executing the `compileTestJava` task.
});
}

@SuppressWarnings("Convert2Lambda")
Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Added this to stop the use of code that can be converted to lambda, but which shouldn't be, showing up as a warning when compiling.

.ifPresent(this::configureTestJava);
}

@SuppressWarnings("Convert2Lambda")
Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Added this to stop the use of code that can be converted to lambda, but which shouldn't be, showing up as a warning when compiling.

@siordache siordache merged commit c8cf42b into java9-modularity:master Aug 6, 2022
@siordache
Copy link
Collaborator

Thanks for this PR!

@big-andy-coates big-andy-coates deleted the issue_211 branch August 8, 2022 14:15
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

javac reports "--add-opens has no effect at compile time"

2 participants