mirror of
https://gitflic.ru/project/openide/openide.git
synced 2026-09-27 10:03:11 +07:00
IDEA-57201 "Optimize imports" drops comments between import statements
1. 'Optimize imports' processing is corrected; 2. Corresponding tests are added;
This commit is contained in:
@@ -141,7 +141,7 @@ public class ImportHelper{
|
||||
try {
|
||||
StringBuilder text = buildImportListText(resultList, classesOrPackagesToImportOnDemand, classesToUseSingle);
|
||||
for (PsiElement nonImport : nonImports) {
|
||||
text.append("\n").append(nonImport);
|
||||
text.append("\n").append(nonImport.getText());
|
||||
}
|
||||
String ext = StdFileTypes.JAVA.getDefaultExtension();
|
||||
PsiFileFactory factory = PsiFileFactory.getInstance(file.getProject());
|
||||
|
||||
Reference in New Issue
Block a user