10642: minor: Add dummy impls for `trace_macros` and `log_syntax` r=Veykril a=Veykril
Both of these are macros for debugging macros and as such don't really need an implementation for us.
Closes https://github.com/rust-analyzer/rust-analyzer/issues/2212
bors r+
Co-authored-by: Lukas Wirth <lukastw97@gmail.com>
10633: fix: Implement most proc_macro span handling for other ABIs r=Veykril a=Veykril
Follow up to #10378
bors r+
Co-authored-by: Lukas Wirth <lukastw97@gmail.com>
10634: minor: Drop resolver and `authors` manifest entry in `limit` r=lnicola a=lnicola
The new resolver is on by default in the 2021 edition,
bors r+
Co-authored-by: Laurențiu Nicola <lnicola@dend.ro>
10631: fix: Fix postfix completions panicking r=Veykril a=Veykril
Fixes https://github.com/rust-analyzer/rust-analyzer/issues/10243, I couldn't reproduce the panic with the given snippet, but this change should still guard against it.
bors r+
Co-authored-by: Lukas Wirth <lukastw97@gmail.com>
10630: fix: Don't ask the user to reload when chaning HoverAction configs in VSCode r=Veykril a=Veykril
To my knowledge, all of these are re-read on hover requests so there is no longer a reason to reload when changing these.
bors r+
Co-authored-by: Lukas Wirth <lukastw97@gmail.com>
10617: Set MSRV r=Veykril a=lnicola
Set the MSRV to `1.56` since we're already on the 2021 edition and building with older version fails.
From now on, there'll be a change in behavior: `xtask install` used to warn on old toolchains, but now the user will get an error. This isn't so bad because:
- the check in `xtask install` wasn't always working (because sometimes `xtask` itself required a newer toolchain)
- we generally bump the required version for a reason (when using a newer feature). We might forget to bump it, but when we do, older toolchains won't work
Co-authored-by: Laurențiu Nicola <lnicola@dend.ro>
10608: Amend the instruction for rustup. r=lnicola a=jhscheer
The current instruction for installation via rustup are misleading.
Co-authored-by: Jan Scheer <jhscheer@users.noreply.github.com>
10603: fix: Don't resolve attributes to non attribute macros r=Veykril a=Veykril
Also changes `const`s to `static`s for `Limit`s as we have interior mutability in those(though only used with a certain feature flag enabled).
Co-authored-by: Lukas Wirth <lukastw97@gmail.com>
10563: feat: Make "Generate getter" assist use semantic info r=agluszak a=agluszak
This PR makes "Generate getter" assist use semantic info instead of dealing with types encoded as strings.
Getters for types which are:
- `Copy` no longer return references
- `AsRef<str>` (i.e. `String`) return `&str` (instead of `&String`)
- `AsRef<[T]>` (i.e. `Vec<T>`) return `&[T]` (instead of `&Vec<T>`)
- `AsRef<T>` (i.e. `Box<T>`) return `&T` (instead of `&Box<T>`)
- `Option<T>` return `Option<&T>` (instead of `&Option<T>`)
- `Result<T, E>` return `Result<&T, &E>` (instead of `&Result<T, E>`)
String, Vec, Box and Option were previously handled as special cases.
Closes#10295
Co-authored-by: Andrzej Głuszak <gluszak.andrzej@gmail.com>