Releases: rust-lang/rust-analyzer
2023-01-30
Changelog #166
Commit: f1b257f
Release: 2023-01-30 (0.3.1386)
New Features
-
#14012(first contribution) add installation instructions for Visual Studio. -
#14024(first contribution) update documentation for Emacs. -
#14041show signature help for record literals: -
#14007add "Open server logs" button to the error notification:
Fixes
#14015(first contribution) don't include lifetime or label apostrophe when renaming.#14020fix associated item search finding unrelated definitions.#14006replace soft breaks in Markdown with spaces.#14019,#14023substitute VS Code variables more generally#14004don't escape non-snippets inMove const to impl.#14011fixUnwrap blockforletstatements.#14037handle boolean scrutinees better inMatch to if-letassist.#14039makeAdd missing impl memberswork for impls inside blocks.#14038don't fail workspace loading if sysroot can't be found
Internal Improvements
#14025improve deduplication inprocess_changes.#14009🧹lsp_ext.ts.#14017removeTypeWalk.#14026try to fix auto-publishing of lib crates.
See also original changelog.
2023-01-23
Changelog #165
Commit: daa0138
Release: 2023-01-23 (0.3.1377)
New Features
-
#13935(first contribution) add assist to desugar doc-comments:desugar-comment.mp4
-
#13947add basic tooltips to adjustment hints: -
#13963unconditionally enable location links in inlay hints.
Fixes
#13983(first contribution) parseconst_closuressyntax.#13993(first contribution) VS Code: substitute variables inconfig.serverPath.#13981don't run flycheck on startup unlesscheckOnSaveis enabled.#13966don't compute layout ifTargetDataLayoutis not available.#13971improve inference for binary operations more precise.#13961don't generatePartialEq/PartialOrdmethods body when types don't match.#13984fix target data layout fetching incorrectly passingrustctorustc.#13978handle slice patterns inFill match arms.#13985don't respond withContentModifiedwhile loading the workspace.#13988fix whitespace handling in hover Markdown removal.#13980fixcheckOnSaveconfig patching.
Internal Improvements
#13964specifyauthors,edition,licenseandrust-versionviaworkspace.package.#13969useworkspace.dependenciesto declare local dependencies.#13989remove hover fallback in favor of ranged hover.#14001replaceSmolStrusage with enum for lang items.
See also original changelog.
2023-01-16
Changelog #164
Commit: ff4d55e
Release: 2023-01-16
New Features
-
#13684(first contribution) addExtract format expressionassist:Screen.Recording.2022-11-29.at.2.39.49.mov
-
#13810(first contribution) add action to expand a macro once, inline -
#13744(first contribution) add the ability to limit the thread pool size (rust-analyzer.numThreads). -
#13816add option to make adjustment (reborrow) hints postfix: -
#13825addUnqualify method callassist: -
#13848colorizecargo checkdiagnostics in the full view in VSCode: -
#13934makeunlinked_filediagnostic quickfixes work for inline modules: -
#13458add assist to replace plain arithmetic operations with wrapping/checked/saturating ones. -
#13946remove hover inlay tooltips, replace them with location links. -
#13799renamecheckOnSavesettings tocheck.
Fixes
#13843(first contribution) add missingawaitin generated delegate methods.#13753(first contribution) increase proc macro expansion token limit (fixes the visitors inswc).#13940(first contribution) fix a panic in thematch-to-let-elseassist.#13763add type bounds to generated#[derive]implementations.#13891keep whitespace in extracted functions.#13890unescape inline module names when resolving modules.#13897resolve inherent methods implemented in ancestor blocks.#13948make inlay hint location links work for more types.#13945handle or-patters in missing match diagnostics.#13923revert "add a ZWNJ to prevent VS Code from forming ligatures between hints and code".
Internal Improvements
#13956(first contribution) upgradecommand-groupto fix build on Haiku OS.#13915make it clearer when the server expects an initialized notification.#13917split outhir-defattribute handling parts intohir-expand.#13933refine reference search for const and function associated items.#13941explain the idea behindrust-project.json.#13928,#13929,#13862,#13919,#13936,#13937fix some Clippy lints.
See also original changelog.
2023-01-09
Changelog #163
Commit: f77b68a
Release: 2023-01-09
New Features
-
#13832add enum variant discriminants hints: -
#13876package Windows release artifacts as ZIP and add symbols file.
Fixes
#13894apply fallback before final obligation resolution.#13854support multi-character punct tokens in MBE.#13877prefix prelude items whose name collides in current scope.#13887only set machine-applicable rustc diagnostics as preferred.#13882remember adjustments introduced by binary operators.#13853use diagnostic code as link to full message.#13886add a ZWNJ to prevent VS Code from forming ligatures between hints and code.#13885skip lifetime elision hints on fn pointers and fn trait types.#13893complete record enum variants without parens when snippets are disabled.
Internal Improvements
#13860fix a bunch of clippy lints.
See also original changelog.
2023-01-02
Changelog #162
Commit: 643bc02
Release: 2023-01-02
New Features
-
#13870,#13875diagnose private field and associated item accesses: -
#13856fix inference oftry {}blocks:
Fixes
#13866(first contribution) userustc_safe_intrinsicattribute to check for intrinsic safety.#13867fall back to inaccessible associated functions and constants if no visible resolutions are found.#13869improve exit point highlighting forforandwhileloops in tail position.#13871merge multiple intersecting ranges to fix panic in "Extract module".
Internal Improvements
See also original changelog.
2022-12-26
Changelog #161
Commit: 74ae2dd
Release: 2022-12-26
New Features
-
#13699implement location links for type inlay hints (disabled until Code 1.76 release because of a bug): -
#13817add option to hide adjustment hints outside ofunsafeblocks and functions:
Fixes
#13805(first contribution) complete enum variants without parens when snippets are disabled.#13794fix "parser seems stuck" panics when parsing colossal files.#13795use the correct edition when formatting code in path dependencies.#13800don't matchletexpressions and inlineconsts inexprMBE fragments.#13820fix binding mode hints always adding parentheses to or-patterns.#13831don't autofill associated type trait bounds when generating an implementation.#13764correctly check for redundant parentheses in theremove_parenthesesassist.#13806skip hints for identity (T->T) adjustments.#13814,#13818calculate theTargetDataLayoutcorrectly for the selected target.#13840handle lifetime variables inCallableSigquery.
Internal Improvements
#13828,#13829,#13835(first contributions) fixredundant_clone,explicit_auto_deref,uninlined_format_argsclippy warnings.#13830use a default derives andstrip_prefix.#13771addxtaskcommand for publishing release notes on GitHub Releases.#13804split inlay hints into modules by type.#13822threadFamousDefsthrough the inlay hints.
See also original changelog.
2022-12-19
Auto merge of #13792 - Veykril:flycheck, r=Veykril Add a command to clear flycheck diagnostics And document the flycheck notifications
2022-12-12
Auto merge of #13756 - flodiebold:simplify-assoc-item-subst, r=flodie…
2022-12-05
Auto merge of #13721 - Veykril:incoherent-impls, r=Veykril Support `rustc_has_incoherent_inherent_impls` Fixes us not resolving `<dyn Error>::downcast` now that `Error` moved to core, while that assoc function is declared in `alloc`.
2022-11-28
Auto merge of #13681 - lowr:fix/extract-function-tail-expr, r=Veykril fix: check tail expressions more precisely in `extract_function` Fixes #13620 When extracting expressions with control flows into a function, we can avoid wrapping tail expressions in `Option` or `Result` when they are also tail expressions of the container we're extracting from (see #7840, #9773). This is controlled by `ContainerInfo::is_in_tail`, but we've been computing it by checking if the tail expression of the range to extract is contained in the container's syntactically last expression, which may be a block that contains both tail and non-tail expressions (e.g. in #13620, the range to be extracted is not a tail expression but we set the flag to true). This PR tries to compute the flag as precise as possible by utilizing `for_each_tail_expr()` (and also moves the flag to `Function` struct as it's more of a property of the function to be extracted than of the container).













![Screenshot showing an <unsize>&raw mut * on the RHS of let ptr: *mut [u8] = &mut []](https://user-images.githubusercontent.com/38225716/208986376-d607de62-8290-4e16-b7fe-15b762dc5f60.png)