From ab88db1aed2ded517d61dd220c1dd762fa295bb3 Mon Sep 17 00:00:00 2001 From: Jack O'Connor Date: Sat, 14 Dec 2019 10:12:56 -0500 Subject: [PATCH] docs tweaks --- README.md | 3 +++ src/lib.rs | 9 +++------ 2 files changed, 6 insertions(+), 6 deletions(-) diff --git a/README.md b/README.md index fbfd82e..9fb8862 100644 --- a/README.md +++ b/README.md @@ -6,3 +6,6 @@ are provided in Rust, enabled by default, with dynamic CPU feature detection. AVX-512 and NEON implementation are available via C FFI, controlled by the `c_avx512` and `c_neon` features. Rayon-based multi-threading is controlled by the `rayon` feature. + +Eventually docs will be published on docs.rs. For now, you can build and +view the docs locally with `cargo doc --open`. diff --git a/src/lib.rs b/src/lib.rs index 05690a5..ddffeac 100644 --- a/src/lib.rs +++ b/src/lib.rs @@ -19,14 +19,11 @@ //! let hash2 = hasher.finalize(); //! assert_eq!(hash1, hash2); //! -//! // Extended output. +//! // Extended output. OutputReader implements std::io::Read. //! # #[cfg(feature = "std")] { //! let mut output = Vec::new(); -//! blake3::Hasher::new() -//! .update(b"foobarbaz") -//! .finalize_xof() -//! .take(1000) -//! .read_to_end(&mut output)?; +//! let mut output_reader = hasher.finalize_xof(); +//! output_reader.take(1000).read_to_end(&mut output)?; //! assert_eq!(output.len(), 1000); //! assert_eq!(&output[..32], hash1.as_bytes()); //! # }