rust-lang / rust-lang/rust-analyzer
When an unstable method is autocompleted and no feature flag is present, add one
Nobody has claimed this yet.
- Dominant language
- Rust
- Stars
- 16.9k
- Forks
- 2.2k
- Avg merge
- 1d 12h
- Merged PRs (30d)
- 72
Description
In the project with nightly toolchain used, Some(22).ex<|> proposes expect_none method which is unstable currently.

But when I autocomplete it, I need to manually add the feature flag to enable the feature.
I would expect RA to add this flag automatically, if not added already.
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Reproduce the autocomplete case described with the nightly toolchain using Some(22).expect_none, then trace the autocomplete handling for unstable methods and feature-flag insertion. Done means accepting the completion adds the required feature flag when it is absent and does not add a duplicate when it is already present.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- rust
- Domain
- developer-experience, tooling
- Issue type
- Feature
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 38/100