Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Organizing imports in module-info.java removes all imports #549

Closed
fbricon opened this issue Feb 12, 2018 · 0 comments
Closed

Organizing imports in module-info.java removes all imports #549

fbricon opened this issue Feb 12, 2018 · 0 comments
Assignees

Comments

@fbricon
Copy link
Contributor

fbricon commented Feb 12, 2018

(Initially reported as redhat-developer/vscode-java#430)

After organizing imports on module-info-java (Shift+Alt+o), this:

import java.sql.Driver;

module mymodule {
	requires java.sql;
	provides Driver with mypackage.MyDriver;
}

becomes

module mymodule {
	requires java.sql;
	provides Driver with mypackage.MyDriver;
}

and the file fails to compile because of the unknown Driver type. It's very annoying when organize imports is triggered on save.

@fbricon fbricon added this to the End February 2018 milestone Feb 12, 2018
@fbricon fbricon self-assigned this Feb 12, 2018
fbricon added a commit to fbricon/eclipse.jdt.ls that referenced this issue Feb 13, 2018
Fixes eclipse-jdtls#549

Signed-off-by: Fred Bricon <fbricon@gmail.com>
fbricon added a commit that referenced this issue Feb 13, 2018
Fixes #549

Signed-off-by: Fred Bricon <fbricon@gmail.com>
tsmaeder pushed a commit to bdshadow/eclipse.jdt.ls that referenced this issue Apr 6, 2018
Fixes eclipse-jdtls#549

Signed-off-by: Fred Bricon <fbricon@gmail.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

1 participant