mirror of
https://github.com/rust-lang/rust.git
synced 2025-05-09 08:27:38 +00:00
![]() MIR printing: print the path of uneval'd const Currently it just prints `const _` which makes it impossible to say which constant is being referred to. Also refer to promoteds in a consistent way; previously MIR printing would do ``` promoted[0] in C1: &Option<Cell<i32>> = { // ... } ``` Now that should be ``` const C1::promoted[0]: &Option<Cell<i32>> = { // ... } ``` We don't seem to have a test for that so I tried it by hand, it seems to work: ``` const main::promoted[12]: &[&str; 3] = { let mut _0: &[&str; 3]; let mut _1: [&str; 3]; let mut _2: &str; let mut _3: &str; let mut _4: &str; let mut _5: &str; bb0: { _3 = const "b"; _2 = &(*_3); _5 = const "c"; _4 = &(*_5); _1 = [const "a", move _2, move _4]; _0 = &_1; return; } } ``` |
||
---|---|---|
.. | ||
error.rs | ||
eval_queries.rs | ||
fn_queries.rs | ||
machine.rs | ||
mod.rs | ||
valtrees.rs |