rustdoc: stop treating everything in a trait item as a method
This was added in0b9b4b7068to fix the spacing on trait pages, but stopped being needed because791f04e5a4stopped styling method-toggle. By only putting the method-toggle class on actual methods, the JS setting does the right thing.
This commit is contained in:
parent
37d7de3379
commit
7e64cebf97
4 changed files with 13 additions and 3 deletions
|
|
@ -4,6 +4,8 @@
|
|||
// summary. Trait methods with no documentation should not be wrapped.
|
||||
//
|
||||
// @has foo/trait.Foo.html
|
||||
// @has - '//details[@class="rustdoc-toggle"]//summary//h4[@class="code-header"]' 'type Item'
|
||||
// @!has - '//details[@class="rustdoc-toggle"]//summary//h4[@class="code-header"]' 'type Item2'
|
||||
// @has - '//details[@class="rustdoc-toggle method-toggle"]//summary//h4[@class="code-header"]' 'is_documented()'
|
||||
// @!has - '//details[@class="rustdoc-toggle method-toggle"]//summary//h4[@class="code-header"]' 'not_documented()'
|
||||
// @has - '//details[@class="rustdoc-toggle method-toggle"]//*[@class="docblock"]' 'is_documented is documented'
|
||||
|
|
@ -11,6 +13,11 @@
|
|||
// @!has - '//details[@class="rustdoc-toggle method-toggle"]//summary//h4[@class="code-header"]' 'not_documented_optional()'
|
||||
// @has - '//details[@class="rustdoc-toggle method-toggle"]//*[@class="docblock"]' 'is_documented_optional is documented'
|
||||
pub trait Foo {
|
||||
/// is documented
|
||||
type Item;
|
||||
|
||||
type Item2;
|
||||
|
||||
fn not_documented();
|
||||
|
||||
/// is_documented is documented
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue