about summary refs log tree commit diff
path: root/src/test
diff options
context:
space:
mode:
authorMichael Goulet <michael@errs.io>2022-09-03 08:05:48 +0000
committerMichael Goulet <michael@errs.io>2022-09-03 08:06:35 +0000
commite9b01c745d52e5bb05ee2e8c184c188b92a349fb (patch)
treeeaa39d13376bd082a08c5e091fc26e95efead759 /src/test
parent0209485578807b8084127f12d57771300edff87a (diff)
downloadrust-e9b01c745d52e5bb05ee2e8c184c188b92a349fb.tar.gz
rust-e9b01c745d52e5bb05ee2e8c184c188b92a349fb.zip
Fix global_asm macro pretty printing
Diffstat (limited to 'src/test')
-rw-r--r--src/test/ui/asm/unpretty-expanded.rs3
-rw-r--r--src/test/ui/asm/unpretty-expanded.stdout9
2 files changed, 12 insertions, 0 deletions
diff --git a/src/test/ui/asm/unpretty-expanded.rs b/src/test/ui/asm/unpretty-expanded.rs
new file mode 100644
index 00000000000..6128f49b89a
--- /dev/null
+++ b/src/test/ui/asm/unpretty-expanded.rs
@@ -0,0 +1,3 @@
+// check-pass
+// compile-flags: -Zunpretty=expanded
+core::arch::global_asm!("x: .byte 42");
diff --git a/src/test/ui/asm/unpretty-expanded.stdout b/src/test/ui/asm/unpretty-expanded.stdout
new file mode 100644
index 00000000000..15b60d1559c
--- /dev/null
+++ b/src/test/ui/asm/unpretty-expanded.stdout
@@ -0,0 +1,9 @@
+#![feature(prelude_import)]
+#![no_std]
+#[prelude_import]
+use ::std::prelude::rust_2015::*;
+#[macro_use]
+extern crate std;
+// check-pass
+// compile-flags: -Zunpretty=expanded
+global_asm! ("x: .byte 42");