about summary refs log tree commit diff
path: root/tests/ui/conditional-compilation
diff options
context:
space:
mode:
Diffstat (limited to 'tests/ui/conditional-compilation')
-rw-r--r--tests/ui/conditional-compilation/cfg-generic-params.rs16
-rw-r--r--tests/ui/conditional-compilation/cfg-generic-params.stderr6
-rw-r--r--tests/ui/conditional-compilation/cfg-in-crate-1.rs2
-rw-r--r--tests/ui/conditional-compilation/cfg-in-crate-1.stderr2
-rw-r--r--tests/ui/conditional-compilation/cfg-non-opt-expr.rs6
-rw-r--r--tests/ui/conditional-compilation/cfg-non-opt-expr.stderr6
-rw-r--r--tests/ui/conditional-compilation/module_with_cfg.rs2
7 files changed, 20 insertions, 20 deletions
diff --git a/tests/ui/conditional-compilation/cfg-generic-params.rs b/tests/ui/conditional-compilation/cfg-generic-params.rs
index 4bb8f8ae94f..6480a0f2479 100644
--- a/tests/ui/conditional-compilation/cfg-generic-params.rs
+++ b/tests/ui/conditional-compilation/cfg-generic-params.rs
@@ -1,18 +1,18 @@
 //@ compile-flags:--cfg yes --check-cfg=cfg(yes,no)
 
-fn f_lt<#[cfg(yes)] 'a: 'a, #[cfg(FALSE)] T>() {}
-fn f_ty<#[cfg(FALSE)] 'a: 'a, #[cfg(yes)] T>() {}
+fn f_lt<#[cfg(yes)] 'a: 'a, #[cfg(false)] T>() {}
+fn f_ty<#[cfg(false)] 'a: 'a, #[cfg(yes)] T>() {}
 
-type FnGood = for<#[cfg(yes)] 'a, #[cfg(FALSE)] T> fn(); // OK
-type FnBad = for<#[cfg(FALSE)] 'a, #[cfg(yes)] T> fn();
+type FnGood = for<#[cfg(yes)] 'a, #[cfg(false)] T> fn(); // OK
+type FnBad = for<#[cfg(false)] 'a, #[cfg(yes)] T> fn();
 //~^ ERROR only lifetime parameters can be used in this context
 
-type PolyGood = dyn for<#[cfg(yes)] 'a, #[cfg(FALSE)] T> Copy; // OK
-type PolyBad = dyn for<#[cfg(FALSE)] 'a, #[cfg(yes)] T> Copy;
+type PolyGood = dyn for<#[cfg(yes)] 'a, #[cfg(false)] T> Copy; // OK
+type PolyBad = dyn for<#[cfg(false)] 'a, #[cfg(yes)] T> Copy;
 //~^ ERROR only lifetime parameters can be used in this context
 
-struct WhereGood where for<#[cfg(yes)] 'a, #[cfg(FALSE)] T> u8: Copy; // OK
-struct WhereBad where for<#[cfg(FALSE)] 'a, #[cfg(yes)] T> u8: Copy;
+struct WhereGood where for<#[cfg(yes)] 'a, #[cfg(false)] T> u8: Copy; // OK
+struct WhereBad where for<#[cfg(false)] 'a, #[cfg(yes)] T> u8: Copy;
 //~^ ERROR only lifetime parameters can be used in this context
 
 fn f_lt_no<#[cfg_attr(FALSE, unknown)] 'a>() {} // OK
diff --git a/tests/ui/conditional-compilation/cfg-generic-params.stderr b/tests/ui/conditional-compilation/cfg-generic-params.stderr
index 563616be36b..bae75dd0deb 100644
--- a/tests/ui/conditional-compilation/cfg-generic-params.stderr
+++ b/tests/ui/conditional-compilation/cfg-generic-params.stderr
@@ -31,7 +31,7 @@ LL | struct WhereYes where for<#[cfg_attr(yes, unknown)] 'a> u8: Copy;
 error[E0658]: only lifetime parameters can be used in this context
   --> $DIR/cfg-generic-params.rs:7:48
    |
-LL | type FnBad = for<#[cfg(FALSE)] 'a, #[cfg(yes)] T> fn();
+LL | type FnBad = for<#[cfg(false)] 'a, #[cfg(yes)] T> fn();
    |                                                ^
    |
    = note: see issue #108185 <https://github.com/rust-lang/rust/issues/108185> for more information
@@ -41,7 +41,7 @@ LL | type FnBad = for<#[cfg(FALSE)] 'a, #[cfg(yes)] T> fn();
 error[E0658]: only lifetime parameters can be used in this context
   --> $DIR/cfg-generic-params.rs:11:54
    |
-LL | type PolyBad = dyn for<#[cfg(FALSE)] 'a, #[cfg(yes)] T> Copy;
+LL | type PolyBad = dyn for<#[cfg(false)] 'a, #[cfg(yes)] T> Copy;
    |                                                      ^
    |
    = note: see issue #108185 <https://github.com/rust-lang/rust/issues/108185> for more information
@@ -51,7 +51,7 @@ LL | type PolyBad = dyn for<#[cfg(FALSE)] 'a, #[cfg(yes)] T> Copy;
 error[E0658]: only lifetime parameters can be used in this context
   --> $DIR/cfg-generic-params.rs:15:57
    |
-LL | struct WhereBad where for<#[cfg(FALSE)] 'a, #[cfg(yes)] T> u8: Copy;
+LL | struct WhereBad where for<#[cfg(false)] 'a, #[cfg(yes)] T> u8: Copy;
    |                                                         ^
    |
    = note: see issue #108185 <https://github.com/rust-lang/rust/issues/108185> for more information
diff --git a/tests/ui/conditional-compilation/cfg-in-crate-1.rs b/tests/ui/conditional-compilation/cfg-in-crate-1.rs
index a1faa2397a3..b9efa32babe 100644
--- a/tests/ui/conditional-compilation/cfg-in-crate-1.rs
+++ b/tests/ui/conditional-compilation/cfg-in-crate-1.rs
@@ -1 +1 @@
-#![cfg(FALSE)] //~ ERROR `main` function not found in crate `cfg_in_crate_1`
+#![cfg(false)] //~ ERROR `main` function not found in crate `cfg_in_crate_1`
diff --git a/tests/ui/conditional-compilation/cfg-in-crate-1.stderr b/tests/ui/conditional-compilation/cfg-in-crate-1.stderr
index 126e10cf040..352baf33091 100644
--- a/tests/ui/conditional-compilation/cfg-in-crate-1.stderr
+++ b/tests/ui/conditional-compilation/cfg-in-crate-1.stderr
@@ -1,7 +1,7 @@
 error[E0601]: `main` function not found in crate `cfg_in_crate_1`
   --> $DIR/cfg-in-crate-1.rs:1:15
    |
-LL | #![cfg(FALSE)]
+LL | #![cfg(false)]
    |               ^ consider adding a `main` function to `$DIR/cfg-in-crate-1.rs`
 
 error: aborting due to 1 previous error
diff --git a/tests/ui/conditional-compilation/cfg-non-opt-expr.rs b/tests/ui/conditional-compilation/cfg-non-opt-expr.rs
index ae85f38e645..cae07ae0ced 100644
--- a/tests/ui/conditional-compilation/cfg-non-opt-expr.rs
+++ b/tests/ui/conditional-compilation/cfg-non-opt-expr.rs
@@ -2,10 +2,10 @@
 #![feature(custom_test_frameworks)]
 
 fn main() {
-    let _ = #[cfg(FALSE)] ();
+    let _ = #[cfg(false)] ();
     //~^ ERROR removing an expression is not supported in this position
-    let _ = 1 + 2 + #[cfg(FALSE)] 3;
+    let _ = 1 + 2 + #[cfg(false)] 3;
     //~^ ERROR removing an expression is not supported in this position
-    let _ = [1, 2, 3][#[cfg(FALSE)] 1];
+    let _ = [1, 2, 3][#[cfg(false)] 1];
     //~^ ERROR removing an expression is not supported in this position
 }
diff --git a/tests/ui/conditional-compilation/cfg-non-opt-expr.stderr b/tests/ui/conditional-compilation/cfg-non-opt-expr.stderr
index 06eaa59efdd..bd1bfeb06c7 100644
--- a/tests/ui/conditional-compilation/cfg-non-opt-expr.stderr
+++ b/tests/ui/conditional-compilation/cfg-non-opt-expr.stderr
@@ -1,19 +1,19 @@
 error: removing an expression is not supported in this position
   --> $DIR/cfg-non-opt-expr.rs:5:13
    |
-LL |     let _ = #[cfg(FALSE)] ();
+LL |     let _ = #[cfg(false)] ();
    |             ^^^^^^^^^^^^^
 
 error: removing an expression is not supported in this position
   --> $DIR/cfg-non-opt-expr.rs:7:21
    |
-LL |     let _ = 1 + 2 + #[cfg(FALSE)] 3;
+LL |     let _ = 1 + 2 + #[cfg(false)] 3;
    |                     ^^^^^^^^^^^^^
 
 error: removing an expression is not supported in this position
   --> $DIR/cfg-non-opt-expr.rs:9:23
    |
-LL |     let _ = [1, 2, 3][#[cfg(FALSE)] 1];
+LL |     let _ = [1, 2, 3][#[cfg(false)] 1];
    |                       ^^^^^^^^^^^^^
 
 error: aborting due to 3 previous errors
diff --git a/tests/ui/conditional-compilation/module_with_cfg.rs b/tests/ui/conditional-compilation/module_with_cfg.rs
index 778379fa6ea..29eb6d43aa7 100644
--- a/tests/ui/conditional-compilation/module_with_cfg.rs
+++ b/tests/ui/conditional-compilation/module_with_cfg.rs
@@ -1,3 +1,3 @@
 //@ ignore-test (auxiliary, used by other tests)
 
-#![cfg_attr(all(), cfg(FALSE))]
+#![cfg_attr(all(), cfg(false))]