Auto merge of #15494 - lnicola:sync-from-rust, r=lnicola

minor: Sync from downstream
This commit is contained in:
bors 2023-08-22 07:58:11 +00:00
commit 7f659a3b2f
11 changed files with 24 additions and 30 deletions

View File

@ -86,6 +86,12 @@ jobs:
- name: Test
run: cargo test ${{ env.USE_SYSROOT_ABI }} -- --nocapture --quiet
- name: Switch to stable toolchain
run: |
rustup update --no-self-update stable
rustup component add --toolchain stable rust-src
rustup default stable
- name: Run analysis-stats on rust-analyzer
if: matrix.os == 'ubuntu-latest'
run: target/${{ matrix.target }}/debug/rust-analyzer analysis-stats .

8
Cargo.lock generated
View File

@ -1196,9 +1196,9 @@ dependencies = [
[[package]]
name = "object"
version = "0.31.1"
version = "0.32.0"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "8bda667d9f2b5051b8833f59f3bf748b28ef54f850f4fcb389a252aa383866d1"
checksum = "77ac5bbd07aea88c60a577a1ce218075ffd59208b2d7ca97adf9bfc5aeb21ebe"
dependencies = [
"memchr",
]
@ -1337,7 +1337,7 @@ name = "proc-macro-api"
version = "0.0.0"
dependencies = [
"memmap2",
"object 0.31.1",
"object 0.32.0",
"paths",
"profile",
"serde",
@ -1357,7 +1357,7 @@ dependencies = [
"libloading",
"mbe",
"memmap2",
"object 0.31.1",
"object 0.32.0",
"paths",
"proc-macro-api",
"proc-macro-test",

View File

@ -368,7 +368,7 @@ pub enum TerminatorKind {
///
/// Only permitted in cleanup blocks. `Resume` is not permitted with `-C unwind=abort` after
/// deaggregation runs.
Resume,
UnwindResume,
/// Indicates that the landing pad is finished and that the process should abort.
///
@ -1057,7 +1057,7 @@ fn for_operand(op: &mut Operand, f: &mut impl FnMut(&mut Place)) {
TerminatorKind::FalseEdge { .. }
| TerminatorKind::FalseUnwind { .. }
| TerminatorKind::Goto { .. }
| TerminatorKind::Resume
| TerminatorKind::UnwindResume
| TerminatorKind::GeneratorDrop
| TerminatorKind::Abort
| TerminatorKind::Return

View File

@ -160,7 +160,7 @@ fn moved_out_of_ref(db: &dyn HirDatabase, body: &MirBody) -> Vec<MovedOutOfRef>
TerminatorKind::FalseEdge { .. }
| TerminatorKind::FalseUnwind { .. }
| TerminatorKind::Goto { .. }
| TerminatorKind::Resume
| TerminatorKind::UnwindResume
| TerminatorKind::GeneratorDrop
| TerminatorKind::Abort
| TerminatorKind::Return
@ -280,7 +280,7 @@ fn dfs(
let targets = match &terminator.kind {
TerminatorKind::Goto { target } => vec![*target],
TerminatorKind::SwitchInt { targets, .. } => targets.all_targets().to_vec(),
TerminatorKind::Resume
TerminatorKind::UnwindResume
| TerminatorKind::Abort
| TerminatorKind::Return
| TerminatorKind::Unreachable => vec![],
@ -371,7 +371,7 @@ fn mutability_of_locals(
};
match &terminator.kind {
TerminatorKind::Goto { .. }
| TerminatorKind::Resume
| TerminatorKind::UnwindResume
| TerminatorKind::Abort
| TerminatorKind::Return
| TerminatorKind::Unreachable

View File

@ -265,7 +265,7 @@ fn fill_body(&mut self, body: &mut MirBody) -> Result<(), MirLowerError> {
self.fill_operand(discr)?;
}
TerminatorKind::Goto { .. }
| TerminatorKind::Resume
| TerminatorKind::UnwindResume
| TerminatorKind::Abort
| TerminatorKind::Return
| TerminatorKind::Unreachable

View File

@ -42,10 +42,11 @@ pub(crate) fn complete_cfg(acc: &mut Completions, ctx: &CompletionContext<'_>) {
};
}
const KNOWN_ARCH: [&str; 19] = [
const KNOWN_ARCH: [&str; 20] = [
"aarch64",
"arm",
"avr",
"csky",
"hexagon",
"mips",
"mips64",

View File

@ -30,6 +30,8 @@
"efiapi",
"avr-interrupt",
"avr-non-blocking-interrupt",
"riscv-interrupt-m",
"riscv-interrupt-s",
"C-cmse-nonsecure-call",
"wasm",
"system",

View File

@ -928,22 +928,6 @@ pub fn device_function() {
ret;
}
```
"##,
},
Lint {
label: "abi_thiscall",
description: r##"# `abi_thiscall`
The tracking issue for this feature is: [#42202]
[#42202]: https://github.com/rust-lang/rust/issues/42202
------------------------
The MSVC ABI on x86 Windows uses the `thiscall` calling convention for C++
instance methods by default; it is identical to the usual (C) calling
convention on x86 Windows except that the first parameter of the method,
the `this` pointer, is passed in the ECX register.
"##,
},
Lint {

View File

@ -12,7 +12,7 @@ rust-version.workspace = true
doctest = false
[dependencies]
object = { version = "0.31.0", default-features = false, features = [
object = { version = "0.32.0", default-features = false, features = [
"std",
"read_core",
"elf",

View File

@ -12,7 +12,7 @@ rust-version.workspace = true
doctest = false
[dependencies]
object = { version = "0.31.0", default-features = false, features = [
object = { version = "0.32.0", default-features = false, features = [
"std",
"read_core",
"elf",

View File

@ -861,6 +861,7 @@ fn resolve_proc_macro() {
bar = {path = "../bar"}
//- /foo/src/main.rs
#![allow(internal_features)]
#![feature(rustc_attrs, decl_macro)]
use bar::Bar;
@ -938,7 +939,7 @@ pub fn foo(_input: TokenStream) -> TokenStream {
let res = server.send_request::<HoverRequest>(HoverParams {
text_document_position_params: TextDocumentPositionParams::new(
server.doc_id("foo/src/main.rs"),
Position::new(11, 9),
Position::new(12, 9),
),
work_done_progress_params: Default::default(),
});