summaryrefslogtreecommitdiffstats
path: root/tests/ui/feature-gates/unstable-attribute-allow-issue-0.rs
blob: bffe43262e096240dee215378bc1397231ad71e6 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
// Check that an issue value can be explicitly set to "0" instead of "none"
#![crate_type = "lib"]
#![feature(staged_api)]
#![stable(feature = "stable_test_feature", since = "1.0.0")]

#[unstable(feature = "unstable_test_feature", issue = "0")]
fn unstable_issue_0() {} //~^ ERROR `issue` must be a non-zero numeric string or "none"

#[unstable(feature = "unstable_test_feature", issue = "none")]
fn unstable_issue_none() {}

#[unstable(feature = "unstable_test_feature", issue = "something")]
fn unstable_issue_not_allowed() {} //~^ ERROR `issue` must be a non-zero numeric string or "none"