eclipse-jdt / eclipse-jdt/eclipse.jdt.core
Autocompletion suggest methods that are outside of the desired compliance level (and then fails to compile)
- Dominant language
- Java
- Stars
- 237
- Forks
- 195
- Avg merge
- 1d 12h
- Merged PRs (30d)
- 47
Description
## The problem
I get autocompletion proposals that are **outside** the compliance level specified in the project, _e.g._

The method `java.util.concurrent.Executors.newThreadPerTaskExecutor(ThreadFactory)` is available starting with Java **21** but the compliance level is set to **17**.
## To reproduce
### Option Nr. 1
- Use JDK 17
- Write `Executors.newT` and open autocompletion
### Option Nr. 2
- Use JDK > 17 (I used **21**)
- Set the _Compiler compliance Level_ to 17 via project properties
- Write `Executors.newT` and open autocompletion

Contributor guide
Assessment
This issue has not been assessed yet.