about summary refs log tree commit diff
path: root/src/test/codegen/cfguard-nochecks.rs
diff options
context:
space:
mode:
authorAndrew Paverd <andrew.paverd@microsoft.com>2020-07-06 16:10:42 +0100
committerAndrew Paverd <andrew.paverd@microsoft.com>2020-07-10 09:56:13 +0100
commit1ca7bfe481a18909e4769a9f6aee58f8cec17b44 (patch)
treeedf2d5ad96413810dd1311344975a594b81ad6e1 /src/test/codegen/cfguard-nochecks.rs
parente1beee4992ad4b235fc700bf7af1ee86f894ea53 (diff)
downloadrust-1ca7bfe481a18909e4769a9f6aee58f8cec17b44.tar.gz
rust-1ca7bfe481a18909e4769a9f6aee58f8cec17b44.zip
Only add cfguard module flag on windows-msvc
Diffstat (limited to 'src/test/codegen/cfguard-nochecks.rs')
-rw-r--r--src/test/codegen/cfguard-nochecks.rs11
1 files changed, 11 insertions, 0 deletions
diff --git a/src/test/codegen/cfguard-nochecks.rs b/src/test/codegen/cfguard-nochecks.rs
new file mode 100644
index 00000000000..d7dc3d7e89e
--- /dev/null
+++ b/src/test/codegen/cfguard-nochecks.rs
@@ -0,0 +1,11 @@
+// compile-flags: -Z control-flow-guard=nochecks
+// only-msvc
+
+#![crate_type = "lib"]
+
+// A basic test function.
+pub fn test() {
+}
+
+// Ensure the module flag cfguard=1 is present
+// CHECK: !"cfguard", i32 1