summaryrefslogtreecommitdiffstats
path: root/src/test/incremental/mir-opt.rs
diff options
context:
space:
mode:
Diffstat (limited to 'src/test/incremental/mir-opt.rs')
-rw-r--r--src/test/incremental/mir-opt.rs11
1 files changed, 11 insertions, 0 deletions
diff --git a/src/test/incremental/mir-opt.rs b/src/test/incremental/mir-opt.rs
new file mode 100644
index 000000000..5bd863439
--- /dev/null
+++ b/src/test/incremental/mir-opt.rs
@@ -0,0 +1,11 @@
+// MIR optimizations can create expansions after the TyCtxt has been created.
+// This test verifies that those expansions can be decoded correctly.
+
+// revisions:rpass1 rpass2
+// compile-flags: -Z query-dep-graph -Z mir-opt-level=3
+
+fn main() {
+ if std::env::var("a").is_ok() {
+ println!("b");
+ }
+}