github rust-lang/rust-analyzer 2024-01-08

latest releases: nightly, 2024-11-11, 2024-11-04...
10 months ago

Changelog #215

Commit: af40101
Release: 2024-01-08 (v0.3.1799)

New Features

  • #16222 (first contribution) add unresolved_assoc_item diagnostic:

    Screenshot showing a diagnostic on a misspelled associated function

  • #16279 support IDE features for tuple fields:

    Screenshot showing hover working on a tuple field, inside a println! call

  • #15933 resolve inherent and implemented associated items in doc comments:

    Screenshot showing associated methods and consts being highlighted in doc comments

  • #16100 add quick fix for unresolved methods when an associated function with the same name exists:

    Screen recording showing quick fixes for invalid method calls where an associated method with the same name exists

  • #16011 add rust-analyzer.cargo.buildScripts.rebuildOnSave option to rebuild proc macros on save if they change.

  • #16223 add quick fix for "Redundant associated item" diagnostic:

    Screen recording showing a quick fix that adds an implemented method to the corresponding trait definition

  • #16298 add inlay hint for exclusive ranges:

Fixes

  • #16081 (first contribution) keep trailing whitespace in doc comments.

  • #16139 (first contribution) give methods a container name.

  • #16136 make the expected completion type a tad smarter with function types:

    Screenshot showing no parantheses when completing a struct field with a function pointer of matching type

  • #16258, #16261, #16267, #16270 rewrite and optimize ImportMap::search_dependencies.

  • #16268 remove result limit for trait-importing method completions.

  • #16153 tell user that linkedProjects is set when failing to discover projects.

  • #16234 fix focus range in attribute/derive upmapping.

  • #16085 fix type inference with IndexMut returning references.

  • #15810 fix panic with macros in "Convert boolean to enum" and "Promot local to constant" assists.

  • #16112, #16264 rewrite "Generate delegate trait" assist.

  • #16067 make "Introduce named generic" assist work with nested types.

  • #16068 pick up new generic names on conflict in "Introduce named generic".

  • #16114 fix Self type replacement in "Inline function".

  • #16199 resolve Self in "Extract struct from enum variant".

  • #16049 don't complete callable parantheses in struct literals.

  • #16241 give a userful error when rustc cannot be found in explicit sysroot.

  • #16285 fix panic on unaligned #[repr(packed)].

  • #16062 update rust-analyzer.cargo.check documentation references to rust-analyzer.check.

Internal Improvements

  • #16179 (first contribution) populate new SCIP SymbolInformation fields.
  • #16213 (first contribution) update dev guide based on the 2024-01-01 release.
  • #16252 (first contribution) switch to expected.assert_eq for ide tests.
  • #15922, #16238, #16262 (first contribution) update Gentoo installation instructions.
  • #16302 (first contribution) add a basic README.md to the line-index crate.
  • #16290 reduce Vec cloning in MIR lowering and eval.
  • #16237 reduce Arc allocations in macro_expand.
  • #16082 migrate assists to the structured snippet API, part 5.
  • clean up and enhance readability of generate_delegate_trait.
  • #16226 expose whether the channel has been dropped in lsp-server errors.
  • #16211 use [workspace.lints.clippy] to configure lints.
  • #16256 only compare relevant parts in ide::{runnables, inlay_hints} tests.
  • #16260 replace single usage of check_expect with check_diagnostics.
  • #16294 fix some minor clippy::perf issues.
  • #16248 add proc-macro-test crate back to the main workspace.
  • #16249 sync from downstream.

See also the changelog post.

Don't miss a new rust-analyzer release

NewReleases is sending notifications on new releases.