rustdoc: Collapse before unindenting

Doesn't make much sense to unindent each line individually and *then* collapse
them all together.
This commit is contained in:
Alex Crichton 2013-09-24 16:08:07 -07:00
parent e7fa081c18
commit bcb8657842
2 changed files with 2 additions and 3 deletions

View File

@ -173,7 +173,6 @@ pub fn collapse_docs(crate: clean::Crate) -> plugins::PluginResult {
(crate, None)
}
// n.b. this is copied from src/librustdoc/unindent_pass.rs
pub fn unindent(s: &str) -> ~str {
let lines = s.any_line_iter().collect::<~[&str]>();
let mut saw_first_line = false;

View File

@ -61,10 +61,10 @@ static PASSES: &'static [Pass] = &[
];
static DEFAULT_PASSES: &'static [&'static str] = &[
"unindent-comments",
"collapse-docs",
"strip-hidden",
"strip-private",
"collapse-docs",
"unindent-comments",
];
local_data_key!(pub ctxtkey: @core::DocContext)