From 1535ad6e39fcdc38f6476a7d3fe29053231e08eb Mon Sep 17 00:00:00 2001 From: Daniel Schadt Date: Tue, 9 Nov 2021 21:17:10 +0100 Subject: fix the doctest --- modderbaas/src/lib.rs | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/modderbaas/src/lib.rs b/modderbaas/src/lib.rs index f9b1c8b..f65e96c 100644 --- a/modderbaas/src/lib.rs +++ b/modderbaas/src/lib.rs @@ -84,9 +84,10 @@ use error::Result; /// /// This function is useful to iterate through the items in a directory and find fitting objects: /// -/// ```rust -/// use modderbaas::minemod::MineMod; -/// let mods = scan("/tmp", |p| MineMod::open(p))?; +/// ```no_run +/// use modderbaas::{scan, minemod::MineMod}; +/// let mods: Vec = scan("/tmp", |p| MineMod::open(p))?; +/// # Ok::<(), Box>(()) /// ``` pub fn scan, F: for<'p> Fn(&'p Path) -> Result>( path: P, -- cgit v1.2.3