eclipse-jdt / eclipse-jdt/eclipse.jdt.core
Completion not available on new line if previous line ends with a comment
Open
- Dominant language
- Java
- Stars
- 237
- Forks
- 195
- Avg merge
- 1d 12h
- Merged PRs (30d)
- 47
Description
In this case, the completion doesn't offer any method:
```java
List strings = Arrays.asList("one", "two", "three");
strings.stream() //
.mapToLong(String::length) // <--- COMMENT TO PREVENT FORMATTER FROM REMOVING LINE-BREAK
. <--- NO COMPLETION
```
If the previous line doesn't end with `//`, the completion works fine.
```java
List strings = Arrays.asList("one", "two", "three");
strings.stream() //
.mapToLong(String::length)
. <--- COMPLETION WORKS FINE
```
Not sure when exactly this bug was introduced, but late 2024 or early 2025.
Contributor guide
Assessment
This issue has not been assessed yet.