]> git.lizzy.rs Git - rust.git/commitdiff
Test that a feature gated cfg variable in a `cfg_attr` on an unconfigured item is...
authorJeffrey Seyfried <jeffrey.seyfried@gmail.com>
Wed, 18 May 2016 01:50:29 +0000 (01:50 +0000)
committerJeffrey Seyfried <jeffrey.seyfried@gmail.com>
Fri, 27 May 2016 00:01:04 +0000 (00:01 +0000)
src/test/compile-fail/expanded-cfg.rs

index 2f74aeba9eb4335d692d82ba2b9ab2e51d532646..a15e0548a86816ab8bb0270d9423dd4c8a5a4915 100644 (file)
@@ -8,7 +8,7 @@
 // option. This file may not be copied, modified, or distributed
 // except according to those terms.
 
-#![feature(rustc_attrs)]
+#![feature(custom_attribute, rustc_attrs)]
 
 macro_rules! mac {
     {} => {
@@ -16,6 +16,9 @@ macro_rules! mac {
         mod m {
             #[lang_item]
             fn f() {}
+
+            #[cfg_attr(target_thread_local, custom)]
+            fn g() {}
         }
     }
 }