Skip to content

Commit fd001c4

Browse files
committed
Auto merge of #134096 - fmease:rollup-0asgoo8, r=fmease
Rollup of 9 pull requests Successful merges: - #133996 (Move most tests for `-l` and `#[link(..)]` into `tests/ui/link-native-libs`) - #134012 (Grammar fixes) - #134032 (docs: better examples for `std::ops::ControlFlow`) - #134040 (bootstrap: print{ln}! -> eprint{ln}! (take 2)) - #134043 (Add test to check unicode identifier version) - #134053 (rustdoc: rename `issue-\d+.rs` tests to have meaningful names (part 10)) - #134055 (interpret: clean up deduplicating allocation functions) - #134073 (dataflow_const_prop: do not eval a ptr address in SwitchInt) - #134084 (Fix typo in RFC mention 3598 -> 3593) r? `@ghost` `@rustbot` modify labels: rollup
2 parents 0cb2cd5 + 6739bad commit fd001c4

File tree

5 files changed

+3
-104
lines changed

5 files changed

+3
-104
lines changed

src/shims/backtrace.rs

+1-9
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,4 @@
11
use rustc_abi::{ExternAbi, Size};
2-
use rustc_ast::ast::Mutability;
32
use rustc_middle::ty::layout::LayoutOf as _;
43
use rustc_middle::ty::{self, Instance, Ty};
54
use rustc_span::{BytePos, Loc, Symbol, hygiene};
@@ -179,14 +178,7 @@ pub trait EvalContextExt<'tcx>: crate::MiriInterpCxExt<'tcx> {
179178

180179
match flags {
181180
0 => {
182-
// These are "mutable" allocations as we consider them to be owned by the callee.
183-
let name_alloc =
184-
this.allocate_str(&name, MiriMemoryKind::Rust.into(), Mutability::Mut)?;
185-
let filename_alloc =
186-
this.allocate_str(&filename, MiriMemoryKind::Rust.into(), Mutability::Mut)?;
187-
188-
this.write_immediate(name_alloc.to_ref(this), &this.project_field(dest, 0)?)?;
189-
this.write_immediate(filename_alloc.to_ref(this), &this.project_field(dest, 1)?)?;
181+
throw_unsup_format!("miri_resolve_frame: v0 is not supported any more");
190182
}
191183
1 => {
192184
this.write_scalar(

src/shims/panic.rs

+2-3
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,6 @@
1212
//! metadata we remembered when pushing said frame.
1313
1414
use rustc_abi::ExternAbi;
15-
use rustc_ast::Mutability;
1615
use rustc_middle::{mir, ty};
1716
use rustc_target::spec::PanicStrategy;
1817

@@ -161,7 +160,7 @@ pub trait EvalContextExt<'tcx>: crate::MiriInterpCxExt<'tcx> {
161160
let this = self.eval_context_mut();
162161

163162
// First arg: message.
164-
let msg = this.allocate_str(msg, MiriMemoryKind::Machine.into(), Mutability::Not)?;
163+
let msg = this.allocate_str_dedup(msg)?;
165164

166165
// Call the lang item.
167166
let panic = this.tcx.lang_items().panic_fn().unwrap();
@@ -180,7 +179,7 @@ pub trait EvalContextExt<'tcx>: crate::MiriInterpCxExt<'tcx> {
180179
let this = self.eval_context_mut();
181180

182181
// First arg: message.
183-
let msg = this.allocate_str(msg, MiriMemoryKind::Machine.into(), Mutability::Not)?;
182+
let msg = this.allocate_str_dedup(msg)?;
184183

185184
// Call the lang item.
186185
let panic = this.tcx.lang_items().panic_nounwind().unwrap();

tests/pass/backtrace/backtrace-api-v0.rs

-69
This file was deleted.

tests/pass/backtrace/backtrace-api-v0.stderr

-18
This file was deleted.

tests/pass/backtrace/backtrace-api-v0.stdout

-5
This file was deleted.

0 commit comments

Comments
 (0)