diff options
| author | Manish Goregaokar <manishsmail@gmail.com> | 2018-01-03 11:33:04 +0530 |
|---|---|---|
| committer | Manish Goregaokar <manishsmail@gmail.com> | 2018-01-22 15:24:29 +0530 |
| commit | c0af89723d5fee5c4bd7b54f7d7885b4faac00d8 (patch) | |
| tree | 847afa112e56f74748d7677e6fd41f2d5e798767 /src/librustdoc/clean | |
| parent | 191e5b0b78eae71ed9d59d03f2292501dd6d488a (diff) | |
Fix tidy
Diffstat (limited to 'src/librustdoc/clean')
| -rw-r--r-- | src/librustdoc/clean/mod.rs | 11 |
1 files changed, 7 insertions, 4 deletions
diff --git a/src/librustdoc/clean/mod.rs b/src/librustdoc/clean/mod.rs index dcf12ed8180..59a797b55d0 100644 --- a/src/librustdoc/clean/mod.rs +++ b/src/librustdoc/clean/mod.rs @@ -834,8 +834,9 @@ impl Clean<Attributes> for [ast::Attribute] { let path = { let is_value; let path_str = if let Some(prefix) = - ["struct", "enum", "type", "trait", "union"].iter() - .find(|p| link.starts_with(**p)) { + ["struct", "enum", "type", + "trait", "union"].iter() + .find(|p| link.starts_with(**p)) { is_value = Some(false); link.trim_left_matches(prefix).trim() } else if let Some(prefix) = @@ -857,7 +858,8 @@ impl Clean<Attributes> for [ast::Attribute] { // avoid resolving things (i.e. regular links) which aren't like paths // FIXME(Manishearth) given that most links have slashes in them might be worth // doing a check for slashes first - if path_str.contains(|ch: char| !(ch.is_alphanumeric() || ch == ':' || ch == '_')) { + if path_str.contains(|ch: char| !(ch.is_alphanumeric() || + ch == ':' || ch == '_')) { continue; } @@ -867,7 +869,8 @@ impl Clean<Attributes> for [ast::Attribute] { if let Some(id) = cx.mod_ids.borrow().last() { cx.resolver.borrow_mut() .with_scope(*id, |resolver| { - resolver.resolve_str_path_error(DUMMY_SP, &path_str, is_val) + resolver.resolve_str_path_error(DUMMY_SP, + &path_str, is_val) }) } else { // FIXME(Manishearth) this branch doesn't seem to ever be hit, really |
