]> git.lizzy.rs Git - rust.git/blob - src/test/rustdoc/deprecated.rs
Rollup merge of #68945 - mjbshaw:once_is_completed, r=LukasKalbertodt
[rust.git] / src / test / rustdoc / deprecated.rs
1 #![feature(deprecated)]
2
3 // @has deprecated/index.html '//*[@class="docblock-short"]/span[@class="stab deprecated"]' \
4 //      'Deprecated'
5 // @has - '//*[@class="docblock-short"]' 'Deprecated docs'
6
7 // @has deprecated/struct.S.html '//*[@class="stab deprecated"]' \
8 //      'Deprecated since 1.0.0: text'
9 /// Deprecated docs
10 #[deprecated(since = "1.0.0", note = "text")]
11 pub struct S;
12
13 // @matches deprecated/index.html '//*[@class="docblock-short"]' '^Docs'
14 /// Docs
15 pub struct T;
16
17 // @matches deprecated/struct.U.html '//*[@class="stab deprecated"]' \
18 //      'Deprecated since 1.0.0$'
19 #[deprecated(since = "1.0.0")]
20 pub struct U;
21
22 // @matches deprecated/struct.V.html '//*[@class="stab deprecated"]' \
23 //      'Deprecated: text$'
24 #[deprecated(note = "text")]
25 pub struct V;
26
27 // @matches deprecated/struct.W.html '//*[@class="stab deprecated"]' \
28 //      'Deprecated$'
29 #[deprecated]
30 pub struct W;
31
32 // @matches deprecated/struct.X.html '//*[@class="stab deprecated"]' \
33 //      'Deprecated: shorthand reason$'
34 #[deprecated = "shorthand reason"]
35 pub struct X;