Skip to content

Commit 622572f

Browse files
committed
tests/debuginfo/basic-stepping.rs: Add revisions default-mir-passes, no-SingleUseConsts-mir-pass
To prevent regressions our test must cover the code both inside and outside of the `SingleUseConsts` MIR pass. Use revisions for that.
1 parent de505d2 commit 622572f

1 file changed

Lines changed: 10 additions & 6 deletions

File tree

tests/debuginfo/basic-stepping.rs

Lines changed: 10 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -10,19 +10,23 @@
1010
// Debugger tests need debuginfo
1111
//@ compile-flags: -g
1212

13+
// FIXME(#128945): SingleUseConsts shouldn't need to be disabled.
14+
//@ revisions: default-mir-passes no-SingleUseConsts-mir-pass
15+
//@ [no-SingleUseConsts-mir-pass] compile-flags: -Zmir-enable-passes=-SingleUseConsts
16+
1317
//@ gdb-command: run
1418
// FIXME(#97083): Should we be able to break on initialization of zero-sized types?
1519
// FIXME(#97083): Right now the first breakable line is:
1620
//@ gdb-check: let mut c = 27;
1721
//@ gdb-command: next
1822
//@ gdb-check: let d = c = 99;
1923
//@ gdb-command: next
20-
// FIXME(#33013): gdb-check: let e = "hi bob";
21-
// FIXME(#33013): gdb-command: next
22-
// FIXME(#33013): gdb-check: let f = b"hi bob";
23-
// FIXME(#33013): gdb-command: next
24-
// FIXME(#33013): gdb-check: let g = b'9';
25-
// FIXME(#33013): gdb-command: next
24+
//@ [no-SingleUseConsts-mir-pass] gdb-check: let e = "hi bob";
25+
//@ [no-SingleUseConsts-mir-pass] gdb-command: next
26+
//@ [no-SingleUseConsts-mir-pass] gdb-check: let f = b"hi bob";
27+
//@ [no-SingleUseConsts-mir-pass] gdb-command: next
28+
//@ [no-SingleUseConsts-mir-pass] gdb-check: let g = b'9';
29+
//@ [no-SingleUseConsts-mir-pass] gdb-command: next
2630
//@ gdb-check: let h = ["whatever"; 8];
2731
//@ gdb-command: next
2832
//@ gdb-check: let i = [1,2,3,4];

0 commit comments

Comments
 (0)