]> git.lizzy.rs Git - rust.git/blob - tests/rustdoc/reexport-stability-tags-unstable-and-portability.rs
Fix problem noticed in PR106859 with char -> u8 suggestion
[rust.git] / tests / rustdoc / reexport-stability-tags-unstable-and-portability.rs
1 #![crate_name = "foo"]
2 #![feature(doc_cfg)]
3 #![feature(staged_api)]
4 #![stable(feature = "rust1", since = "1.0.0")]
5
6 #[stable(feature = "rust1", since = "1.0.0")]
7 pub mod tag {
8     #[unstable(feature = "humans", issue = "none")]
9     pub trait Unstable {}
10
11     #[stable(feature = "rust1", since = "1.0.0")]
12     #[doc(cfg(feature = "sync"))]
13     pub trait Portability {}
14
15     #[unstable(feature = "humans", issue = "none")]
16     #[doc(cfg(feature = "sync"))]
17     pub trait Both {}
18
19     #[stable(feature = "rust1", since = "1.0.0")]
20     pub trait None {}
21 }
22
23 // @has foo/mod1/index.html
24 #[stable(feature = "rust1", since = "1.0.0")]
25 pub mod mod1 {
26     // @has - '//code' 'pub use tag::Unstable;'
27     // @has - '//span' 'Experimental'
28     // @!has - '//span' 'sync'
29     #[stable(feature = "rust1", since = "1.0.0")]
30     pub use tag::Unstable;
31 }
32
33 // @has foo/mod2/index.html
34 #[stable(feature = "rust1", since = "1.0.0")]
35 pub mod mod2 {
36     // @has - '//code' 'pub use tag::Portability;'
37     // @!has - '//span' 'Experimental'
38     // @has - '//span' 'sync'
39     #[stable(feature = "rust1", since = "1.0.0")]
40     pub use tag::Portability;
41 }
42
43 // @has foo/mod3/index.html
44 #[stable(feature = "rust1", since = "1.0.0")]
45 pub mod mod3 {
46     // @has - '//code' 'pub use tag::Both;'
47     // @has - '//span' 'Experimental'
48     // @has - '//span' 'sync'
49     #[stable(feature = "rust1", since = "1.0.0")]
50     pub use tag::Both;
51 }
52
53 // @has foo/mod4/index.html
54 #[stable(feature = "rust1", since = "1.0.0")]
55 pub mod mod4 {
56     // @has - '//code' 'pub use tag::None;'
57     // @!has - '//span' 'Experimental'
58     // @!has - '//span' 'sync'
59     #[stable(feature = "rust1", since = "1.0.0")]
60     pub use tag::None;
61 }