]> git.lizzy.rs Git - rust.git/blob - tests/rustdoc/keyword.rs
Rollup merge of #107580 - lenko-d:default_value_for_a_lifetime_generic_parameter_prod...
[rust.git] / tests / rustdoc / keyword.rs
1 #![crate_name = "foo"]
2
3 #![feature(rustdoc_internals)]
4
5 // @has foo/index.html '//h2[@id="keywords"]' 'Keywords'
6 // @has foo/index.html '//a[@href="keyword.match.html"]' 'match'
7 // @has foo/index.html '//div[@class="sidebar-elems"]//li/a' 'Keywords'
8 // @has foo/index.html '//div[@class="sidebar-elems"]//li/a/@href' '#keywords'
9 // @has foo/keyword.match.html '//a[@class="keyword"]' 'match'
10 // @has foo/keyword.match.html '//h1' 'Keyword match'
11 // @has foo/keyword.match.html '//section[@id="main-content"]//div[@class="docblock"]//p' 'this is a test!'
12 // @has foo/index.html '//a/@href' '../foo/index.html'
13 // @!has foo/foo/index.html
14 // @!has-dir foo/foo
15 // @!has foo/index.html '//span' '🔒'
16 #[doc(keyword = "match")]
17 /// this is a test!
18 mod foo{}
19
20 // @has foo/keyword.foo.html '//section[@id="main-content"]//div[@class="docblock"]//p' 'hello'
21 #[doc(keyword = "foo")]
22 /// hello
23 mod bar {}