diff options
| author | Alex Crichton <alex@alexcrichton.com> | 2013-10-12 14:58:37 -0700 |
|---|---|---|
| committer | Alex Crichton <alex@alexcrichton.com> | 2013-10-14 18:00:54 -0700 |
| commit | 4d2a402555aedd04affc978ef05324df7550fd07 (patch) | |
| tree | fb7cf76b7ab6a764601f2029602f067135bfb787 | |
| parent | 3d693d74b814eed6140b9ca29ff01eb3411255a2 (diff) | |
| download | rust-4d2a402555aedd04affc978ef05324df7550fd07.tar.gz rust-4d2a402555aedd04affc978ef05324df7550fd07.zip | |
rustdoc: Don't abort if there's nothing to document
Instead there's no index.html file emitted because there wasn't anything to document. Closes #9828
| -rw-r--r-- | src/librustdoc/html/render.rs | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/librustdoc/html/render.rs b/src/librustdoc/html/render.rs index 5b27adb2967..3fc7988fd82 100644 --- a/src/librustdoc/html/render.rs +++ b/src/librustdoc/html/render.rs @@ -220,7 +220,7 @@ pub fn run(mut crate: clean::Crate, dst: Path) { }; mkdir(&cx.dst); - match crate.module.get_ref().doc_list() { + match crate.module.as_ref().map(|m| m.doc_list().unwrap_or(&[])) { Some(attrs) => { for attr in attrs.iter() { match *attr { |
