Skip to content

Commit

Permalink
Test that a feature gated cfg variable in a cfg_attr on an unconfig…
Browse files Browse the repository at this point in the history
…ured item is allowed
  • Loading branch information
jseyfried committed May 27, 2016
1 parent 15d5074 commit 3636ce7
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion src/test/compile-fail/expanded-cfg.rs
Original file line number Diff line number Diff line change
Expand Up @@ -8,14 +8,17 @@
// 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 {
{} => {
#[cfg(attr)]
mod m {
#[lang_item]
fn f() {}

#[cfg_attr(target_thread_local, custom)]
fn g() {}
}
}
}
Expand Down

0 comments on commit 3636ce7

Please sign in to comment.