| Age | Commit message (Collapse) | Author | Lines |
|
Rollup of 9 pull requests
Successful merges:
- rust-lang/rust#132469 (Do not suggest borrow that is already there in fully-qualified call)
- rust-lang/rust#143340 (awhile -> a while where appropriate)
- rust-lang/rust#143438 (Fix the link in `rustdoc.md`)
- rust-lang/rust#143539 (Regression tests for repr ICEs)
- rust-lang/rust#143566 (Fix `x86_64-unknown-netbsd` platform support page)
- rust-lang/rust#143572 (Remove unused allow attrs)
- rust-lang/rust#143583 (`loop_match`: fix 'no terminator on block')
- rust-lang/rust#143584 (make `Machine::load_mir` infallible)
- rust-lang/rust#143591 (Fix missing words in future tracking issue)
r? `@ghost`
`@rustbot` modify labels: rollup
|
|
awhile -> a while where appropriate
|
|
Allow custom default address spaces and parse `p-` specifications in the datalayout string
Some targets, such as CHERI, use as default an address space different from the "normal" default address space `0` (in the case of CHERI, [200 is used](https://www.cl.cam.ac.uk/techreports/UCAM-CL-TR-877.pdf)). Currently, `rustc` does not allow to specify custom address spaces and does not take into consideration [`p-` specifications in the datalayout string](https://llvm.org/docs/LangRef.html#langref-datalayout).
This patch tries to mitigate these problems by allowing targets to define a custom default address space (while keeping the default value to address space `0`) and adding the code to parse the `p-` specifications in `rustc_abi`. The main changes are that `TargetDataLayout` now uses functions to refer to pointer-related informations, instead of having specific fields for the size and alignment of pointers in the default address space; furthermore, the two `pointer_size` and `pointer_align` fields in `TargetDataLayout` are replaced with an `FxHashMap` that holds info for all the possible address spaces, as parsed by the `p-` specifications.
The potential performance drawbacks of not having ad-hoc fields for the default address space will be tested in this PR's CI run.
r? workingjubilee
|
|
default data address space
|
|
chore: Remove dead field from `InferenceContext`
|
|
|
|
Add AsMut, Borrow and BorrowMut to minicore and famous_defs
|
|
fix: Avoid .unwrap() when running the discover command
|
|
fix: Fix diverging destructuring assignments
|
|
`hir_ty::match_check` cleanup: remove special handling for box patterns
|
|
They need to return `!`, unlike diverging ordinary assignments. See the comment in the code.
|
|
|
|
|
|
|
|
Previously, the following configuration in settings.json:
"rust-analyzer.workspace.discoverConfig": {
"command": [
"oops",
"develop-json",
"{arg}"
],
"progressLabel": "rust-analyzer",
"filesToWatch": [
"BUCK",
"TARGETS"
]
},
Would previously cause a crash in rust-analyzer:
thread 'LspServer' panicked at crates/rust-analyzer/src/main_loop.rs:776:84:
called `Result::unwrap()` on an `Err` value: Os { code: 2, kind: NotFound, message: "No such file or directory" }
Instead, use more specific panic messages.
|
|
Improve flycheck and build script progress reporting
|
|
|
|
|
|
Fix: Resolve HIR display length issues and improve adjustment tooltips
|
|
Co-authored-by: Giga Bowser <45986823+Giga-Bowser@users.noreply.github.com>
|
|
fix: Honor `rust-analyzer.cargo.noDeps` option when fetching sysroot metadata
|
|
Migrate `unmerge_match_arm` Assist to use `SyntaxEditor`
|
|
fix: Fix some things with builtin derives
|
|
load_workspace`
|
|
1. Err on unions on derive where it's required.
2. Err on `#[derive(Default)]` on enums without `#[default]` variant.
3. Don't add where bounds `T: Default` when expanding `Default` on enums (structs need that, enums not).
Also, because I was annoyed by that, in minicore, add a way to filter on multiple flags in the line-filter (`// :`). This is required for the `Debug` and `Hash` derives, because the derive should be in the prelude but the trait not.
|
|
Signed-off-by: Hayashi Mikihiro <34ttrweoewiwe28@gmail.com>
|
|
fix: Incorrect closure capturing for let exprs
|
|
fix: resolve item in match bind
|
|
Signed-off-by: Hayashi Mikihiro <34ttrweoewiwe28@gmail.com>
|
|
|
|
fix: Improve diagnostic ranges for `macro_calls!`
|
|
We used to point to the entire macro call including its token tree if we couldn't upmap the diagnostic to the input
This generally makes things very noisy as the entire macro call will turn red on errors.
Instead, we now macro the path and `!` (bang) token as the error source range which is a lot nicer on the eyes.
|
|
Always couple `--compile-time-deps` with
|
|
`--all-targets` coupled with `--compile-time-deps` will never actually build binaries and so it won't fail for targets where libtest is missing
|
|
fix: Do not warn about proc-macro srv when sysroot is missing
|
|
|
|
Re-enable fixpoint iteration for variance computation
|
|
|
|
Bump salsa
|
|
|
|
Workaround missing none group support in builtin macros
|
|
Restructure proc-macro loading erros, differentiate hard error property on kind
|
|
|
|
if the link target is inferred
That is, do it for `[macro foo]`, but not for `[macro foo](macro foo)`.
|
|
|
|
|
|
|
|
Signed-off-by: Hayashi Mikihiro <34ttrweoewiwe28@gmail.com>
|
|
Signed-off-by: Hayashi Mikihiro <34ttrweoewiwe28@gmail.com>
|
|
Signed-off-by: Hayashi Mikihiro <34ttrweoewiwe28@gmail.com>
|