Show hidden items with rustdoc's document-private

When using `#[doc(hidden)]` elements are hidden from docs even when the
rustdoc flag `--document-private-items` is set.

This behavior has been changed to display all hidden items when the flag
is active.
This commit is contained in:
Christian Duerr 2017-11-30 21:18:00 +01:00
parent 0a2e9ade83
commit ec337b613e
No known key found for this signature in database
GPG Key ID: 85CDAE3C164BA7B4
2 changed files with 15 additions and 1 deletions

View File

@ -470,7 +470,6 @@ where R: 'static + Send, F: 'static + Send + FnOnce(Output) -> R {
default_passes = false;
passes = vec![
String::from("strip-hidden"),
String::from("collapse-docs"),
String::from("unindent-comments"),
];

View File

@ -0,0 +1,15 @@
// Copyright 2015 The Rust Project Developers. See the COPYRIGHT
// file at the top-level directory of this distribution and at
// http://rust-lang.org/COPYRIGHT.
//
// Licensed under the Apache License, Version 2.0 <LICENSE-APACHE or
// http://www.apache.org/licenses/LICENSE-2.0> or the MIT license
// <LICENSE-MIT or http://opensource.org/licenses/MIT>, at your
// option. This file may not be copied, modified, or distributed
// except according to those terms.
// compile-flags: --document-private-items
// @has issue_46380/struct.Hidden.html
#[doc(hidden)]
pub struct Hidden;