mirror of
https://github.com/rust-lang/rust.git
synced 2024-11-02 07:22:42 +00:00
Add test for rustc_const_unstable on methods
This commit is contained in:
parent
eb7384d479
commit
2a281e0a76
@ -32,3 +32,12 @@ pub const unsafe fn bar2_gated() -> u32 { 42 }
|
||||
|
||||
// @has 'foo/fn.bar_not_gated.html' '//pre' 'pub unsafe fn bar_not_gated() -> u32'
|
||||
pub const unsafe fn bar_not_gated() -> u32 { 42 }
|
||||
|
||||
pub struct Foo;
|
||||
|
||||
impl Foo {
|
||||
// @has 'foo/struct.Foo.html' '//h4[@id="method.gated"]/code' 'pub unsafe fn gated() -> u32'
|
||||
#[stable(feature = "rust1", since = "1.0.0")]
|
||||
#[rustc_const_unstable(feature="foo", issue = "none")]
|
||||
pub const unsafe fn gated() -> u32 { 42 }
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user