about summary refs log tree commit diff
path: root/src/tools/rust-analyzer
AgeCommit message (Collapse)AuthorLines
2025-09-19fix: Fix one more thing in `in-rust-tree`Shoyu Vanilla-1/+1
2025-09-18Merge pull request #20694 from ShoyuVanilla/bump-rustcLaurențiu Nicola-49/+62
minor: Yet another rustc crates bump
2025-09-19minor: Yet another rustc crates bumpShoyu Vanilla-49/+62
2025-09-19fix: Fix `indexmap` with `in-rust-tree`Shoyu Vanilla-6/+1
2025-09-18Bump rustc crates againLaurențiu Nicola-57/+50
2025-09-18chore: Update rustc depsShoyu Vanilla-30/+44
2025-09-18Fix applicable after l_curly for replace_is_method_with_if_let_methodA4-Tacks-0/+18
2025-09-18Merge pull request #20664 from ChayimFriedman2/coerce-nsChayim Refael Friedman-3944/+9358
fix: Port a bunch of stuff from rustc and fix a bunch of type mismatches/diagnostics
2025-09-17Merge pull request #20682 from A4-Tacks/fix-change-vis-applicable-on-variantShoyu Vanilla (Flint)-0/+14
Fix applicable on variant field for change_visibility
2025-09-17Fix applicable on variant field for change_visibilityA4-Tacks-0/+14
Enum variant fields do not allow visibility Example --- ```rust enum Foo { Variant($0String), } ``` **Before this PR**: ```rust enum Foo { Variant(pub(crate) String), } ``` **After this PR**: Assist not applicable
2025-09-17Merge pull request #20583 from btj/comments-enableChayim Refael Friedman-18/+156
Add `rust-analyzer.semanticHighlighting.comments.enable`
2025-09-17Add the `rust-analyzer.semanticHighlighting.comments.enable` configuration valueBart Jacobs-18/+156
2025-09-17Fix complete type in nested patternA4-Tacks-0/+20
Example --- ```rust struct Foo { num: u32 } struct Bar(Foo); fn foo(Bar($0)) {} ``` **Before this PR**: ```rust struct Foo { num: u32 } struct Bar(Foo); fn foo(Bar(Foo { num$1 }: Foo$0)) {} ``` **After this PR**: ```rust struct Foo { num: u32 } struct Bar(Foo); fn foo(Bar(Foo { num$1 }$0)) {} ```
2025-09-17Merge pull request #20379 from skewb1k/fix/consistent-hover-doc-breaksChayim Refael Friedman-42/+42
fix(hover): unify horizontal rule formatting to `---`
2025-09-17Fix "sync-from-ra" for `rust-lang/rust`Shoyu Vanilla-0/+6
2025-09-16Merge pull request #20612 from Veykril/veykril/push-vzuykrsxvrtsLukas Wirth-46/+49
fix: Fix expand macro recursively not working correctly for nested macro calls
2025-09-16Merge pull request #20402 from rust-lang/veykril/push-pursotqxutsxLukas Wirth-3/+22
Add more workaround hacks for incorrect startup diagnostics
2025-09-16Merge pull request #20517 from Veykril/veykril/push-wrurmtqppzusLukas Wirth-101/+144
fix: Only compute unstable paths on nightly toolchains for IDE features
2025-09-16Add more workaround hacks for incorrect startup diagnosticsLukas Wirth-8/+16
2025-09-16Workaround lsp-types typoLukas Wirth-1/+12
2025-09-16fix: Only compute unstable paths on nightly toolchains for IDE featuresLukas Wirth-101/+144
2025-09-16fix: Fix expand macro recursively not working correctly for nested macro callsLukas Wirth-46/+49
2025-09-16fix: More precise clause filtering for `explicit_*_predicates_of`Shoyu Vanilla-6/+20
2025-09-15Port a bunch of stuff from rustc and fix a bunch of type mismatches/diagnosticsChayim Refael Friedman-3944/+9358
This started from porting coercion, but ended with porting much more.
2025-09-15Merge pull request #20669 from ChayimFriedman2/testing-guideLaurențiu Nicola-0/+107
internal: Add a testing guide
2025-09-15Add a testing guideChayim Refael Friedman-0/+107
2025-09-15Merge pull request #20667 from ChayimFriedman2/ns-cleanup2Chayim Refael Friedman-0/+34
internal: Add Regression Test For The One And The Only Issue #5514
2025-09-15Add Regression Test For The One And The Only Issue #5514Chayim Refael Friedman-0/+34
2025-09-15Merge pull request #20652 from ChayimFriedman2/cli-diagsLaurențiu Nicola-14/+56
internal: Improve `rust-analyzer diagnostics`
2025-09-15Merge pull request #20665 from ChayimFriedman2/error-notableShoyu Vanilla (Flint)-0/+29
fix: Don't mark unknown type as implementing every notable trait
2025-09-15Add regression tests to some S-blocked-on-new-solver issuesChayim Refael Friedman-1/+137
That were fixed by the migration.
2025-09-15Don't mark unknown type as implementing every notable traitChayim Refael Friedman-0/+29
Because the new solver, will return "yes" for them (which is a good thing).
2025-09-14Improve `rust-analyzer diagnostics`Chayim Refael Friedman-14/+56
In my experience the `processing <module>` messages make it harder to search for the actual diagnostics, so remove them and instead print the filename only if there is a diagnostic. Also allow choosing the minimum severity.
2025-09-14Merge pull request #20654 from ShoyuVanilla/predicatesChayim Refael Friedman-2/+61
fix: Infinite loop while elaborting predicates
2025-09-14fix: Infinite loop while elaborting predicatesShoyu Vanilla-2/+61
2025-09-14Merge pull request #20635 from iorizu/fix-double-flycheckShoyu Vanilla (Flint)-133/+170
fix: Don't trigger two flychecks when saving files that are part of targets
2025-09-12Fix extra semicolon before else in let-stmtA4-Tacks-1/+51
Example --- ```rust fn main() { let x = if true { () } $0 else {}; } ``` **Before this PR**: ```rust fn main() { let x = if true { () } else if $1 { $0 }; else {}; } ``` **After this PR**: ```rust fn main() { let x = if true { () } else if $1 { $0 } else {}; } ```
2025-09-11Minor refactoringIfeanyi Orizu-140/+170
2025-09-11Merge pull request #20642 from ChayimFriedman2/wasm-safeShoyu Vanilla (Flint)-89/+257
fix: Make `#[target_feature]` always safe on WASM
2025-09-11Merge pull request #20653 from A4-Tacks/gen-function-empty-gen-paramLaurențiu Nicola-1/+30
Fix empty generic param list for generate_function
2025-09-11Fix empty generic param list for generate_functionA4-Tacks-1/+30
Example --- ```rust struct Foo<S>(S); impl<S> Foo<S> { fn foo(&self) { self.bar()$0; } } ``` **Before this PR**: ```rust struct Foo<S>(S); impl<S> Foo<S> { fn foo(&self) { self.bar(); } fn bar<>(&self) ${0:-> _} { todo!() } } ``` **After this PR**: ```rust struct Foo<S>(S); impl<S> Foo<S> { fn foo(&self) { self.bar(); } fn bar(&self) ${0:-> _} { todo!() } } ```
2025-09-10Merge pull request #20649 from ChayimFriedman2/cast-unknownShoyu Vanilla (Flint)-6/+25
fix: Always coerce in a cast, even when there are unknown types
2025-09-10Always coerce in a cast, even when there are unknown typesChayim Refael Friedman-6/+25
This cause the relationships between inference vars to get recorded.
2025-09-10Merge pull request #20645 from ChayimFriedman2/update-rustcShoyu Vanilla (Flint)-330/+468
internal: Upgrade rustc crates
2025-09-10Merge pull request #20647 from ChayimFriedman2/ns-projectionsShoyu Vanilla (Flint)-199/+266
fix: Fix normalization in the new solver
2025-09-10Properly handle normalizationChayim Refael Friedman-198/+235
Previously normalization was broken, which caused a lot of fake errors. This fix most type mismatches of the new solver, and it also reverts many test regressions. The downside is that now `chalk_ir::TyKind::AssociatedType`/`chalk_ir::TyKind::Alias` cannot be trusted anymore with their roles, namely: `AssociatedType` is always fully normalized and `Alias` only if it can possibly be normalized further. That seems okay as the new solver does not have this distinction at all (due to it being a lazy normalizer), so this will only hold for the migration time. This does mean we have to change some APIs, notably `hir::Type::walk()` and `TyFingerprint`, to treat `Alias` the same as `AssociatedType`. Another small thing this commit does is to isolate processing of user-written types (currently involving replacing error types and normalizing, but in the future validation will also be needed) to separate functions.
2025-09-10An associated type is not a projection!Chayim Refael Friedman-1/+31
More correctly, a `TyKind::AssociatedType` is not the same as `TyKind::Projection`. We used to map next-solver `TyKind::Alias` to Chalk's `TyKind::AssociatedType`. This is very incorrect, as `AssociatedType` is assumed to be fully normalized, and caused a lot of type mismatches. Unfortunately fixing this causes a lot of stack overflows, because the next solver doesn't have something akin to `AssociatedType` so we normalize again and again. The reason is that is the lazy-normalization nature of the next solver, which means we need to stop normalizing everything. This will be fixed in the next commit.
2025-09-10Adopt even more custom types in the new solverChayim Refael Friedman-222/+220
A lot of simplification and fun.
2025-09-10Upgrade rustc crates and handle changes to canonicalizationChayim Refael Friedman-116/+256
They have to do with diagnostics, we could probably not support them but we will also someday want good diagnostics. The code is mostly copied from rustc.
2025-09-09Merge pull request #20613 from A4-Tacks/diag-unresolved-field-fixes-wsDavid Barsky-13/+52
Fix indent for unresolved_field fixes