Why IDEA inserts an extra space after a string constant when reformatting the code

已回答

I wrote some code like this.

public class Test {
public static void main(String[] args) {
System.out.println(Arrays.asList("a", "b", "c"));
}
}

But IDEA always inserts an extra space after the string constant after reformatting which like the following.

public class Test {
public static void main(String[] args) {
System.out.println(Arrays.asList("a" , "b" , "c" ));
}
}

I got a code style file from my team member and import it. But it does not work. 

My IntelliJ version is 2018.1.3(Ultimate Edition Build #IU-181.4892.42)

0

Do you use some external formatter plug-in like Eclipse Formatter or have .editorconfig file in the project?

Can you share a sample project with the project level code style that will reproduce this issue?

0

请先登录再写评论。