about summary refs log tree commit diff
path: root/src/tools/rust-analyzer
AgeCommit message (Collapse)AuthorLines
2025-01-24Lazily compute location links in type hints againLukas Wirth-9/+18
2025-01-24Record the use tree index in glob importsLukas Wirth-95/+112
2025-01-24Add a new failing test that overflows stackShoyu Vanilla-0/+37
2025-01-24Merge pull request #19012 from ShoyuVanilla/arbitrary-selfLukas Wirth-26/+129
feat: Implement `arbitrary-self-types`
2025-01-24feat: Implement `arbitrary-self-types`Shoyu Vanilla-26/+129
2025-01-24Merge pull request #19017 from Veykril/push-uktrsknwmsvyLukas Wirth-10/+26
fix: Fix flycheck panicking with "once" invocation strategy
2025-01-24Merge pull request #18993 from ChayimFriedman2/iter-configLukas Wirth-56/+111
feat: Provide a config to control auto-insertion of `await` and `iter()`
2025-01-24Merge pull request #18994 from Wilfred/failed_rustc_cfg_as_warningLukas Wirth-1/+1
internal: Treat cfg fetching failures as a warning
2025-01-24Merge pull request #19016 from Veykril/push-moqnsytyrupuLukas Wirth-208/+234
fix: Fix `ItemScope` not recording glob imports
2025-01-24fix: Fix flycheck panicking with "once" invocation strategyLukas Wirth-10/+26
We only ever have one flycheck runner no matter the number of workspaces, so just kick off flycheck for it immediately
2025-01-24Fix `ItemScope` not recording glob importsLukas Wirth-208/+234
This caused us other code to incorrectly assume in dealing with a declaration when in fact it was dealing with a glob imported definition
2025-01-23Check cfg when collecting macro defsDavid Richey-0/+6
2025-01-23Rephrase commentLaurențiu Nicola-3/+3
2025-01-22increase `AUTODEREF_RECURSION_LIMIT` to 20Teodor Tanasoaia-2/+2
The limit was introduced in https://github.com/rust-lang/rust-analyzer/pull/1408#discussion_r294059044 to avoid infinite cycles but it effectively caps the number of derefs to 10. Types like `ID3D12Device14` from the `windows` crate run into this because it derefs to `ID3D12Device13`, 13 to 12 and so on. Increasing it to 20 is a quick fix; a better cycle detection method would be nicer long term.
2025-01-21manual: Document all rust-project.json fieldsWilfred Hughes-8/+84
Ensure that all the fields that rust-analyzer understands are in the manual, they all have doc comments, and they use consistent punctuation (`;` rather than mixing `,` and `;`). Whilst we're here, fix the `sysroot_src` example and add 2024 as a legal value for Rust edition.
2025-01-21internal: Treat cfg fetching failures as a warningWilfred Hughes-1/+1
If the user doesn't have rustc on $PATH, rust-analyzer won't be able to run `rustc --print cfg`. This isn't really an error, as rust-analyzer can still proceed without it. This is particularly noticeable when loading crates defined in a rust-project.json. Until the configuration is loaded, the opened files are briefly treated as detached files and users see this error. Environments with rust-project.json generally have a sysroot and rustc elsewhere, so the error confuses users.
2025-01-21Provide a config to control auto-insertion of `await` and `iter()`Chayim Refael Friedman-56/+111
2025-01-21Keep already computed inlay hint properties instead of late resolving themLukas Wirth-92/+99
2025-01-21Make `InlayHint::linked_location` computation lazyLukas Wirth-204/+285
2025-01-21remove is_pwr2Luuk Wester-17/+3
2025-01-21switch from using leading zeros to trailing zerosLuuk Wester-1/+4
2025-01-21Fix Param::as_local treating closures wrongLukas Wirth-53/+67
2025-01-21Sort completion items that skip `await` and `iter()` behind those that don'tChayim Refael Friedman-0/+26
I don't think my ranking is perfect, because it places them even behind snippet completions, but this is something.
2025-01-21make large niche description more terse, switch to using u128::is_power_of_twoLuuk Wester-5/+5
2025-01-21Merge pull request #18986 from Veykril/push-zlwvwlowpzqmLukas Wirth-0/+49
Goto `Display::fmt` when invoked on `to_string`
2025-01-21Cleanup `Name` string renderingLukas Wirth-249/+145
2025-01-21Merge pull request #18977 from ChayimFriedman2/fix-upmappingLukas Wirth-13/+68
fix: Fix missing upmapping in trait impls completion
2025-01-20Fix another bug with completion of trait items inside macrosChayim Refael Friedman-11/+36
This time, when completing the keyword (e.g. `fn` + whitespace). The bug was actually a double-bug: First, we did not resolve the impl in the macro-expanded file but in the real file, which of course cannot work. Second, in analysis the whitespace was correlated with the `impl` and not the incomplete `fn`, which caused fake (where we insert an identifier after the whitespace) and real expansions to go out of sync, which failed analysis. The fix is to skip whitespaces in analysis.
2025-01-20fix: Only refresh syntax tree view when the active document changesGiga Bowser-1/+8
2025-01-20Goto `Display::fmt` when invoked on `to_string`Lukas Wirth-0/+49
2025-01-20Bring back goto def redirect for parse -> FromStrLukas Wirth-4/+59
2025-01-20Move dual blanket impl logic from source analyzer to goto_defLukas Wirth-114/+93
2025-01-20fix: upmap ranges in convert_tuple_struct_to_named_struct assistVishruth-Thimmaiah-1/+101
fixes #18766
2025-01-20Merge pull request #18967 from Veykril/push-pwonkmwqmmolLukas Wirth-265/+368
Properly record meaningful imports as re-exports in symbol index
2025-01-20Merge pull request #18934 from 1hakusai1/goto_definition_from_intoLukas Wirth-2/+278
feat: Add the ability to jump from `into` to `from` definitions
2025-01-20Merge pull request #18982 from Veykril/push-lstmvzsowxytLukas Wirth-7/+15
Extract variable assist triggers less eagerly
2025-01-20Merge pull request #18972 from ↵Lukas Wirth-12/+42
osiewicz/drop-outgoing-messages-on-background-thread lsp-server: Drop outgoing messages on background thread
2025-01-20Merge pull request #18976 from ChayimFriedman2/non-module-generic-argsLukas Wirth-29/+81
fix: Fix a bug where enum variants were not considered properly in type ns resolution
2025-01-20Fix import search not discarding rawnessLukas Wirth-29/+65
2025-01-20Less allocsLukas Wirth-19/+30
2025-01-20Preserve impl assoc names in ImplDataLukas Wirth-89/+78
2025-01-20Vec -> Box<[_]>Lukas Wirth-9/+6
2025-01-20Properly record meaningful imports as re-exports in symbol indexLukas Wirth-143/+213
2025-01-20Add a test case1hakusai1-0/+24
2025-01-20Use Semantics::resolve_method_call_as_callable to find implementation1hakusai1-59/+89
2025-01-20Merge pull request #18981 from Fabian-Gruenbichler/proc-macro-srv-portabilityLaurențiu Nicola-3/+10
proc-macro-srv: make usage of RTLD_DEEPBIND portable
2025-01-20proc-macro-srv: make usage of RTLD_DEEPBIND portableFabian Grünbichler-3/+10
the constant is wrong on some platforms (e.g., on mips64el it's 0x10, and 0x8 is RTLD_NOLOAD which makes all this functionality broken), the libc crate takes care of those differences for us. fallback to not setting the flag in non-glibc environments - some of them might have support for it using a different value that we don't know about, and some of them lack it entirely. Signed-off-by: Fabian Grünbichler <f.gruenbichler@proxmox.com>
2025-01-20Bump rustc cratesLaurențiu Nicola-17/+17
2025-01-20Merge from rust-lang/rustLaurențiu Nicola-0/+4
2025-01-20Preparing for merge from rust-lang/rustLaurențiu Nicola-1/+1