]>
git.proxmox.com Git - rustc.git/blob - src/test/rustdoc/unindent.rs
3 // @has foo/struct.Example.html
4 // @matches - '//pre[@class="rust rust-example-rendered"]' \
5 // '(?m)let example = Example::new\(\)\n \.first\(\)\n \.second\(\)\n \.build\(\);\Z'
7 /// let example = Example::new()
9 #[cfg_attr(not(feature = "one"), doc = " .second()")]
14 // @has foo/struct.F.html
15 // @matches - '//pre[@class="rust rust-example-rendered"]' \
16 // '(?m)let example = Example::new\(\)\n \.first\(\)\n \.another\(\)\n \.build\(\);\Z'
18 ///let example = Example::new()
20 #[cfg_attr(not(feature = "one"), doc = " .another()")]
25 // @has foo/struct.G.html
26 // @matches - '//pre[@class="rust rust-example-rendered"]' \
27 // '(?m)let example = Example::new\(\)\n\.first\(\)\n \.another\(\)\n\.build\(\);\Z'
29 ///let example = Example::new()
31 #[cfg_attr(not(feature = "one"), doc = " .another()")]
36 // @has foo/struct.H.html
37 // @has - '//div[@class="docblock"]/p' 'no whitespace lol'
42 // @has foo/struct.I.html
43 // @matches - '//pre[@class="rust rust-example-rendered"]' '(?m)4 whitespaces!\Z'
48 // @has foo/struct.J.html
49 // @matches - '//div[@class="docblock"]/p' '(?m)a\nno whitespace\nJust some text.\Z'
52 #[doc = include_str!("unindent.md")]
55 // @has foo/struct.K.html
56 // @matches - '//pre[@class="rust rust-example-rendered"]' '(?m)4 whitespaces!\Z'
61 #[doc = include_str!("unindent.md")]