zkp-merkle-tree 0.1.0

Merkle tree based vector commitment
Documentation
Build #189790 2019-10-07T04:36:51.694777+00:00
# rustc version
rustc 1.39.0-nightly (66bf391c3 2019-09-23)# docs.rs version
docsrs 0.6.0 (0868fa4 2019-10-01)# build log
[INFO] running `"docker" "create" "-v" "/home/cratesfyi/workspace/builds/zkp-merkle-tree-0.1.0/target:/opt/rustwide/target:rw,Z" "-v" "/home/cratesfyi/workspace/builds/zkp-merkle-tree-0.1.0/source:/opt/rustwide/workdir:ro,Z" "-v" "/home/cratesfyi/workspace/cargo-home:/opt/rustwide/cargo-home:ro,Z" "-v" "/home/cratesfyi/workspace/rustup-home:/opt/rustwide/rustup-home:ro,Z" "-e" "SOURCE_DIR=/opt/rustwide/workdir" "-e" "MAP_USER_ID=1001" "-e" "CARGO_TARGET_DIR=/opt/rustwide/target" "-e" "RUSTFLAGS=" "-e" "RUSTDOCFLAGS=-Z unstable-options --resource-suffix -20190923-1.39.0-nightly-66bf391c3 --static-root-path / --disable-per-crate-search --extern-html-root-url crunchy=https://docs.rs/crunchy/0.2.2 --extern-html-root-url zkp_mmap_vec=https://docs.rs/zkp-mmap-vec/0.1.0 --extern-html-root-url hex=https://docs.rs/hex/0.4.0 --extern-html-root-url itertools=https://docs.rs/itertools/0.8.0 --extern-html-root-url no_std_compat=https://docs.rs/no-std-compat/0.1.1 --extern-html-root-url zkp_error_utils=https://docs.rs/zkp-error-utils/0.1.0 --extern-html-root-url rayon=https://docs.rs/rayon/1.2.0 --extern-html-root-url zkp_hash=https://docs.rs/zkp-hash/0.1.0" "-e" "CARGO_HOME=/opt/rustwide/cargo-home" "-e" "RUSTUP_HOME=/opt/rustwide/rustup-home" "-w" "/opt/rustwide/workdir" "-m" "3221225472" "--network" "none" "rustops/crates-build-env" "/opt/rustwide/cargo-home/bin/cargo" "+nightly-2019-09-24" "doc" "--lib" "--no-deps" "--target" "x86_64-unknown-linux-gnu"`
[INFO] [stderr] WARNING: Your kernel does not support swap limit capabilities or the cgroup is not mounted. Memory limited without swap.
[INFO] [stdout] c85fcfb57c3ef7292dd2eb64d1ab000daebbdd1319a39bb84f0755e79bb30313
[INFO] running `"docker" "start" "-a" "c85fcfb57c3ef7292dd2eb64d1ab000daebbdd1319a39bb84f0755e79bb30313"`
[INFO] [stderr]    Compiling proc-macro2 v1.0.5
[INFO] [stderr]    Compiling semver-parser v0.7.0
[INFO] [stderr]    Compiling unicode-xid v0.2.0
[INFO] [stderr]    Compiling syn v1.0.5
[INFO] [stderr]    Compiling libc v0.2.62
[INFO] [stderr]    Compiling getrandom v0.1.12
[INFO] [stderr]     Checking cfg-if v0.1.10
[INFO] [stderr]    Compiling arrayvec v0.4.11
[INFO] [stderr]    Compiling hex v0.4.0
[INFO] [stderr]    Compiling crunchy v0.2.2
[INFO] [stderr]     Checking ppv-lite86 v0.2.5
[INFO] [stderr]     Checking nodrop v0.1.13
[INFO] [stderr]     Checking lazy_static v1.4.0
[INFO] [stderr]     Checking scopeguard v1.0.0
[INFO] [stderr]     Checking either v1.5.3
[INFO] [stderr]    Compiling log v0.4.8
[INFO] [stderr]     Checking no-std-compat v0.1.1
[INFO] [stderr]    Compiling rayon-core v1.6.0
[INFO] [stderr]     Checking remove_dir_all v0.5.2
[INFO] [stderr]     Checking zkp-error-utils v0.1.0
[INFO] [stderr]    Compiling semver v0.9.0
[INFO] [stderr]     Checking crossbeam-utils v0.6.6
[INFO] [stderr]     Checking itertools v0.8.0
[INFO] [stderr]     Checking c2-chacha v0.2.2
[INFO] [stderr]    Compiling rustc_version v0.2.3
[INFO] [stderr]     Checking crossbeam-queue v0.1.2
[INFO] [stderr]     Checking tiny-keccak v1.5.0
[INFO] [stderr]    Compiling quote v1.0.2
[INFO] [stderr]     Checking num_cpus v1.10.1
[INFO] [stderr]     Checking memmap v0.7.0
[INFO] [stderr]     Checking rand_core v0.5.1
[INFO] [stderr]    Compiling memoffset v0.5.1
[INFO] [stderr]     Checking rand_chacha v0.2.1
[INFO] [stderr]     Checking rand v0.7.2
[INFO] [stderr]     Checking crossbeam-epoch v0.7.2
[INFO] [stderr]     Checking crossbeam-deque v0.7.1
[INFO] [stderr]     Checking rayon v1.2.0
[INFO] [stderr]     Checking tempfile v3.1.0
[INFO] [stderr]     Checking zkp-mmap-vec v0.1.0
[INFO] [stderr]    Compiling zkp-macros-lib v0.1.0
[INFO] [stderr]    Compiling proc-macro-hack v0.5.10
[INFO] [stderr]    Compiling zkp-macros-impl v0.1.0
[INFO] [stderr]     Checking zkp-macros-decl v0.1.0
[INFO] [stderr]     Checking zkp-u256 v0.1.0
[INFO] [stderr]     Checking zkp-primefield v0.1.0
[INFO] [stderr]     Checking zkp-hash v0.1.0
[INFO] [stderr]  Documenting zkp-merkle-tree v0.1.0 (/opt/rustwide/workdir)
[INFO] [stderr] warning: Documentation test in private item
[INFO] [stderr]   --> src/index.rs:10:1
[INFO] [stderr]    |
[INFO] [stderr] 10 | / /// Index into a balanced binary tree
[INFO] [stderr] 11 | | ///
[INFO] [stderr] 12 | | /// The index has two representations, as a (depth, offset) pair and as an
[INFO] [stderr] 13 | | /// index.
[INFO] [stderr] ...  |
[INFO] [stderr] 29 | | /// and nodes in the tree. Nodes are indexed in breadth-first order, starting
[INFO] [stderr] 30 | | /// with the root at 0.
[INFO] [stderr]    | |_______________________^
[INFO] [stderr]    |
[INFO] [stderr] note: lint level defined here
[INFO] [stderr]   --> src/lib.rs:30:5
[INFO] [stderr]    |
[INFO] [stderr] 30 |     private_doc_tests,
[INFO] [stderr]    |     ^^^^^^^^^^^^^^^^^
[INFO] [stderr] 
[INFO] [stderr] warning: Missing code example in this documentation
[INFO] [stderr]   --> src/lib.rs:5:1
[INFO] [stderr]    |
[INFO] [stderr] 5  | / #![cfg_attr(not(feature = "std"), no_std)]
[INFO] [stderr] 6  | | #![forbid(unsafe_code)]
[INFO] [stderr] 7  | | #![warn(
[INFO] [stderr] 8  | |     // Enable sets of warnings
[INFO] [stderr] ...  |
[INFO] [stderr] 71 | | use index::Index;
[INFO] [stderr] 72 | | use node::Node;
[INFO] [stderr]    | |_______________^
[INFO] [stderr]    |
[INFO] [stderr] note: lint level defined here
[INFO] [stderr]   --> src/lib.rs:29:5
[INFO] [stderr]    |
[INFO] [stderr] 29 |     missing_doc_code_examples,
[INFO] [stderr]    |     ^^^^^^^^^^^^^^^^^^^^^^^^^
[INFO] [stderr] 
[INFO] [stderr] warning: Missing code example in this documentation
[INFO] [stderr]   --> src/commitment.rs:9:1
[INFO] [stderr]    |
[INFO] [stderr] 9  | / pub struct Commitment {
[INFO] [stderr] 10 | |     size: usize,
[INFO] [stderr] 11 | |     hash: Hash,
[INFO] [stderr] 12 | | }
[INFO] [stderr]    | |_^
[INFO] [stderr] 
[INFO] [stderr] warning: Missing code example in this documentation
[INFO] [stderr]   --> src/commitment.rs:10:5
[INFO] [stderr]    |
[INFO] [stderr] 10 |     size: usize,
[INFO] [stderr]    |     ^^^^^^^^^^^
[INFO] [stderr] 
[INFO] [stderr] warning: Missing code example in this documentation
[INFO] [stderr]   --> src/commitment.rs:11:5
[INFO] [stderr]    |
[INFO] [stderr] 11 |     hash: Hash,
[INFO] [stderr]    |     ^^^^^^^^^^
[INFO] [stderr] 
[INFO] [stderr] warning: Missing code example in this documentation
[INFO] [stderr]   --> src/proof.rs:11:1
[INFO] [stderr]    |
[INFO] [stderr] 11 | / pub struct Proof {
[INFO] [stderr] 12 | |     commitment: Commitment,
[INFO] [stderr] 13 | |     indices:    Vec<usize>,
[INFO] [stderr] 14 | |     hashes:     Vec<Hash>,
[INFO] [stderr] 15 | | }
[INFO] [stderr]    | |_^
[INFO] [stderr] 
[INFO] [stderr] warning: Missing code example in this documentation
[INFO] [stderr]   --> src/proof.rs:12:5
[INFO] [stderr]    |
[INFO] [stderr] 12 |     commitment: Commitment,
[INFO] [stderr]    |     ^^^^^^^^^^^^^^^^^^^^^^
[INFO] [stderr] 
[INFO] [stderr] warning: Missing code example in this documentation
[INFO] [stderr]   --> src/proof.rs:13:5
[INFO] [stderr]    |
[INFO] [stderr] 13 |     indices:    Vec<usize>,
[INFO] [stderr]    |     ^^^^^^^^^^^^^^^^^^^^^^
[INFO] [stderr] 
[INFO] [stderr] warning: Missing code example in this documentation
[INFO] [stderr]   --> src/proof.rs:14:5
[INFO] [stderr]    |
[INFO] [stderr] 14 |     hashes:     Vec<Hash>,
[INFO] [stderr]    |     ^^^^^^^^^^^^^^^^^^^^^
[INFO] [stderr] 
[INFO] [stderr] warning: Missing code example in this documentation
[INFO] [stderr]   --> src/tree.rs:37:1
[INFO] [stderr]    |
[INFO] [stderr] 37 | / /// Merkle tree
[INFO] [stderr] 38 | | ///
[INFO] [stderr] 39 | | /// The tree will become the owner of the `Container`. This is necessary because
[INFO] [stderr] 40 | | /// when low layer-omission is implemented we need immutable access to the
[INFO] [stderr] 41 | | /// leaves. If shared ownership is required the `Container` can be an `Rc<_>`.
[INFO] [stderr]    | |______________________________________________________________________________^
[INFO] [stderr] 
[INFO] [stderr] warning: Missing code example in this documentation
[INFO] [stderr]   --> src/tree.rs:47:5
[INFO] [stderr]    |
[INFO] [stderr] 47 |     commitment: Commitment,
[INFO] [stderr]    |     ^^^^^^^^^^^^^^^^^^^^^^
[INFO] [stderr] 
[INFO] [stderr] warning: Missing code example in this documentation
[INFO] [stderr]   --> src/tree.rs:48:5
[INFO] [stderr]    |
[INFO] [stderr] 48 |     nodes:      MmapVec<Hash>,
[INFO] [stderr]    |     ^^^^^^^^^^^^^^^^^^^^^^^^^
[INFO] [stderr] 
[INFO] [stderr] warning: Missing code example in this documentation
[INFO] [stderr]   --> src/tree.rs:49:5
[INFO] [stderr]    |
[INFO] [stderr] 49 |     leaves:     Container,
[INFO] [stderr]    |     ^^^^^^^^^^^^^^^^^^^^^
[INFO] [stderr] 
[INFO] [stderr] warning: Missing code example in this documentation
[INFO] [stderr]   --> src/result.rs:7:1
[INFO] [stderr]    |
[INFO] [stderr] 7  | / pub enum Error {
[INFO] [stderr] 8  | |     TreeToLarge,
[INFO] [stderr] 9  | |     NumLeavesNotPowerOfTwo,
[INFO] [stderr] 10 | |     IndexOutOfRange,
[INFO] [stderr] ...  |
[INFO] [stderr] 14 | |     RootHashMismatch,
[INFO] [stderr] 15 | | }
[INFO] [stderr]    | |_^
[INFO] [stderr] 
[INFO] [stderr] warning: Missing code example in this documentation
[INFO] [stderr]  --> src/result.rs:8:5
[INFO] [stderr]   |
[INFO] [stderr] 8 |     TreeToLarge,
[INFO] [stderr]   |     ^^^^^^^^^^^
[INFO] [stderr] 
[INFO] [stderr] warning: Missing code example in this documentation
[INFO] [stderr]  --> src/result.rs:9:5
[INFO] [stderr]   |
[INFO] [stderr] 9 |     NumLeavesNotPowerOfTwo,
[INFO] [stderr]   |     ^^^^^^^^^^^^^^^^^^^^^^
[INFO] [stderr] 
[INFO] [stderr] warning: Missing code example in this documentation
[INFO] [stderr]   --> src/result.rs:10:5
[INFO] [stderr]    |
[INFO] [stderr] 10 |     IndexOutOfRange,
[INFO] [stderr]    |     ^^^^^^^^^^^^^^^
[INFO] [stderr] 
[INFO] [stderr] warning: Missing code example in this documentation
[INFO] [stderr]   --> src/result.rs:11:5
[INFO] [stderr]    |
[INFO] [stderr] 11 |     IndicesUnsortedOrDuplicate,
[INFO] [stderr]    |     ^^^^^^^^^^^^^^^^^^^^^^^^^^
[INFO] [stderr] 
[INFO] [stderr] warning: Missing code example in this documentation
[INFO] [stderr]   --> src/result.rs:12:5
[INFO] [stderr]    |
[INFO] [stderr] 12 |     DuplicateLeafMismatch,
[INFO] [stderr]    |     ^^^^^^^^^^^^^^^^^^^^^
[INFO] [stderr] 
[INFO] [stderr] warning: Missing code example in this documentation
[INFO] [stderr]   --> src/result.rs:13:5
[INFO] [stderr]    |
[INFO] [stderr] 13 |     NotEnoughHashes,
[INFO] [stderr]    |     ^^^^^^^^^^^^^^^
[INFO] [stderr] 
[INFO] [stderr] warning: Missing code example in this documentation
[INFO] [stderr]   --> src/result.rs:14:5
[INFO] [stderr]    |
[INFO] [stderr] 14 |     RootHashMismatch,
[INFO] [stderr]    |     ^^^^^^^^^^^^^^^^
[INFO] [stderr] 
[INFO] [stderr] warning: Missing code example in this documentation
[INFO] [stderr]   --> src/commitment.rs:1:1
[INFO] [stderr]    |
[INFO] [stderr] 1  | / use crate::{Error, Index, Result};
[INFO] [stderr] 2  | | use itertools::Itertools;
[INFO] [stderr] 3  | | use std::prelude::v1::*;
[INFO] [stderr] 4  | | use zkp_error_utils::require;
[INFO] [stderr] ...  |
[INFO] [stderr] 60 | |     }
[INFO] [stderr] 61 | | }
[INFO] [stderr]    | |_^
[INFO] [stderr] 
[INFO] [stderr] warning: Missing code example in this documentation
[INFO] [stderr]   --> src/commitment.rs:14:1
[INFO] [stderr]    |
[INFO] [stderr] 14 | / impl Commitment {
[INFO] [stderr] 15 | |     pub fn from_size_hash(size: usize, hash: &Hash) -> Result<Self> {
[INFO] [stderr] 16 | |         require!(
[INFO] [stderr] 17 | |             size == 0 || size.is_power_of_two(),
[INFO] [stderr] ...  |
[INFO] [stderr] 60 | |     }
[INFO] [stderr] 61 | | }
[INFO] [stderr]    | |_^
[INFO] [stderr] 
[INFO] [stderr] warning: Missing code example in this documentation
[INFO] [stderr]   --> src/commitment.rs:15:5
[INFO] [stderr]    |
[INFO] [stderr] 15 | /     pub fn from_size_hash(size: usize, hash: &Hash) -> Result<Self> {
[INFO] [stderr] 16 | |         require!(
[INFO] [stderr] 17 | |             size == 0 || size.is_power_of_two(),
[INFO] [stderr] 18 | |             Error::NumLeavesNotPowerOfTwo
[INFO] [stderr] ...  |
[INFO] [stderr] 23 | |         })
[INFO] [stderr] 24 | |     }
[INFO] [stderr]    | |_____^
[INFO] [stderr] 
[INFO] [stderr] warning: Missing code example in this documentation
[INFO] [stderr]   --> src/commitment.rs:26:5
[INFO] [stderr]    |
[INFO] [stderr] 26 | /     pub fn size(&self) -> usize {
[INFO] [stderr] 27 | |         self.size
[INFO] [stderr] 28 | |     }
[INFO] [stderr]    | |_____^
[INFO] [stderr] 
[INFO] [stderr] warning: Missing code example in this documentation
[INFO] [stderr]   --> src/commitment.rs:30:5
[INFO] [stderr]    |
[INFO] [stderr] 30 | /     pub fn hash(&self) -> &Hash {
[INFO] [stderr] 31 | |         &self.hash
[INFO] [stderr] 32 | |     }
[INFO] [stderr]    | |_____^
[INFO] [stderr] 
[INFO] [stderr] warning: Missing code example in this documentation
[INFO] [stderr]   --> src/commitment.rs:34:5
[INFO] [stderr]    |
[INFO] [stderr] 34 | /     /// Convert leaf indices to a sorted list of unique `Index`s and validates
[INFO] [stderr] 35 | |     /// their range.
[INFO] [stderr]    | |____________________^
[INFO] [stderr] 
[INFO] [stderr] warning: Missing code example in this documentation
[INFO] [stderr]   --> src/commitment.rs:46:5
[INFO] [stderr]    |
[INFO] [stderr] 46 |     /// The number of hashes in the proof for the given set of indices.
[INFO] [stderr]    |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[INFO] [stderr] 
[INFO] [stderr] warning: Missing code example in this documentation
[INFO] [stderr]   --> src/lib.rs:44:1
[INFO] [stderr]    |
[INFO] [stderr] 44 | / /// Implements Vector Commitments using Merkle Trees.
[INFO] [stderr] 45 | | ///
[INFO] [stderr] 46 | | /// <https://eprint.iacr.org/2011/495.pdf>
[INFO] [stderr]    | |__________________________________________^
[INFO] [stderr] 
[INFO] [stderr] warning: Missing code example in this documentation
[INFO] [stderr]   --> src/node.rs:1:1
[INFO] [stderr]    |
[INFO] [stderr] 1  | / use zkp_hash::{Hash, Hashable, MaskedKeccak};
[INFO] [stderr] 2  | |
[INFO] [stderr] 3  | | #[derive(Clone)]
[INFO] [stderr] 4  | | #[cfg_attr(feature = "std", derive(Debug))]
[INFO] [stderr] ...  |
[INFO] [stderr] 13 | |     }
[INFO] [stderr] 14 | | }
[INFO] [stderr]    | |_^
[INFO] [stderr] 
[INFO] [stderr] warning: Missing code example in this documentation
[INFO] [stderr]    --> src/proof.rs:1:1
[INFO] [stderr]     |
[INFO] [stderr] 1   | / use crate::{Commitment, Error, Index, Node, Result};
[INFO] [stderr] 2   | | use itertools::Itertools;
[INFO] [stderr] 3   | | use std::{collections::VecDeque, prelude::v1::*};
[INFO] [stderr] 4   | | use zkp_error_utils::require;
[INFO] [stderr] ...   |
[INFO] [stderr] 101 | |     }
[INFO] [stderr] 102 | | }
[INFO] [stderr]     | |_^
[INFO] [stderr] 
[INFO] [stderr] warning: Missing code example in this documentation
[INFO] [stderr]    --> src/proof.rs:17:1
[INFO] [stderr]     |
[INFO] [stderr] 17  | / impl Proof {
[INFO] [stderr] 18  | |     pub fn from_hashes(
[INFO] [stderr] 19  | |         commitment: &Commitment,
[INFO] [stderr] 20  | |         indices: &[usize],
[INFO] [stderr] ...   |
[INFO] [stderr] 101 | |     }
[INFO] [stderr] 102 | | }
[INFO] [stderr]     | |_^
[INFO] [stderr] 
[INFO] [stderr] warning: Missing code example in this documentation
[INFO] [stderr]   --> src/proof.rs:18:5
[INFO] [stderr]    |
[INFO] [stderr] 18 | /     pub fn from_hashes(
[INFO] [stderr] 19 | |         commitment: &Commitment,
[INFO] [stderr] 20 | |         indices: &[usize],
[INFO] [stderr] 21 | |         hashes: &[Hash],
[INFO] [stderr] ...  |
[INFO] [stderr] 33 | |         })
[INFO] [stderr] 34 | |     }
[INFO] [stderr]    | |_____^
[INFO] [stderr] 
[INFO] [stderr] warning: Missing code example in this documentation
[INFO] [stderr]   --> src/proof.rs:36:5
[INFO] [stderr]    |
[INFO] [stderr] 36 | /     pub fn hashes(&self) -> &[Hash] {
[INFO] [stderr] 37 | |         &self.hashes
[INFO] [stderr] 38 | |     }
[INFO] [stderr]    | |_____^
[INFO] [stderr] 
[INFO] [stderr] warning: Missing code example in this documentation
[INFO] [stderr]    --> src/proof.rs:40:5
[INFO] [stderr]     |
[INFO] [stderr] 40  | /     pub fn verify<Leaf: Hashable>(&self, leafs: &[(usize, Leaf)]) -> Result<()> {
[INFO] [stderr] 41  | |         // TODO: Pass leafs by reference?
[INFO] [stderr] 42  | |         // TODO: Check if the indices line up.
[INFO] [stderr] 43  | |
[INFO] [stderr] ...   |
[INFO] [stderr] 100 | |         Ok(())
[INFO] [stderr] 101 | |     }
[INFO] [stderr]     | |_____^
[INFO] [stderr] 
[INFO] [stderr] warning: Missing code example in this documentation
[INFO] [stderr]   --> src/result.rs:1:1
[INFO] [stderr]    |
[INFO] [stderr] 1  | / #[cfg(feature = "std")]
[INFO] [stderr] 2  | | use std::error;
[INFO] [stderr] 3  | | use std::fmt;
[INFO] [stderr] 4  | | pub type Result<T> = std::result::Result<T, Error>;
[INFO] [stderr] ...  |
[INFO] [stderr] 38 | |     }
[INFO] [stderr] 39 | | }
[INFO] [stderr]    | |_^
[INFO] [stderr] 
[INFO] [stderr] warning: Missing code example in this documentation
[INFO] [stderr]  --> src/result.rs:4:1
[INFO] [stderr]   |
[INFO] [stderr] 4 | pub type Result<T> = std::result::Result<T, Error>;
[INFO] [stderr]   | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[INFO] [stderr] 
[INFO] [stderr] warning: Missing code example in this documentation
[INFO] [stderr]    --> src/tree.rs:1:1
[INFO] [stderr]     |
[INFO] [stderr] 1   | / use crate::{Commitment, Error, Index, Node, Proof, Result, VectorCommitment};
[INFO] [stderr] 2   | | use std::collections::VecDeque;
[INFO] [stderr] 3   | | use zkp_error_utils::require;
[INFO] [stderr] 4   | | use zkp_hash::{Hash, Hashable};
[INFO] [stderr] ...   |
[INFO] [stderr] 289 | |     }
[INFO] [stderr] 290 | | }
[INFO] [stderr]     | |_^
[INFO] [stderr] 
[INFO] [stderr] warning: Missing code example in this documentation
[INFO] [stderr]    --> src/tree.rs:52:1
[INFO] [stderr]     |
[INFO] [stderr] 52  | / impl<Container: VectorCommitment> Tree<Container> {
[INFO] [stderr] 53  | |     pub fn from_leaves(leaves: Container) -> Result<Self> {
[INFO] [stderr] 54  | |         Self::from_leaves_skip_layers(leaves, 1)
[INFO] [stderr] 55  | |     }
[INFO] [stderr] ...   |
[INFO] [stderr] 185 | |     }
[INFO] [stderr] 186 | | }
[INFO] [stderr]     | |_^
[INFO] [stderr] 
[INFO] [stderr] warning: Missing code example in this documentation
[INFO] [stderr]   --> src/tree.rs:53:5
[INFO] [stderr]    |
[INFO] [stderr] 53 | /     pub fn from_leaves(leaves: Container) -> Result<Self> {
[INFO] [stderr] 54 | |         Self::from_leaves_skip_layers(leaves, 1)
[INFO] [stderr] 55 | |     }
[INFO] [stderr]    | |_____^
[INFO] [stderr] 
[INFO] [stderr] warning: Missing code example in this documentation
[INFO] [stderr]    --> src/tree.rs:57:5
[INFO] [stderr]     |
[INFO] [stderr] 57  | /     pub fn from_leaves_skip_layers(leaves: Container, skip_layers: usize) -> Result<Self> {
[INFO] [stderr] 58  | |         let size = leaves.len();
[INFO] [stderr] 59  | |         if size == 0 {
[INFO] [stderr] 60  | |             return Ok(Self {
[INFO] [stderr] ...   |
[INFO] [stderr] 120 | |         })
[INFO] [stderr] 121 | |     }
[INFO] [stderr]     | |_____^
[INFO] [stderr] 
[INFO] [stderr] warning: Missing code example in this documentation
[INFO] [stderr]    --> src/tree.rs:123:5
[INFO] [stderr]     |
[INFO] [stderr] 123 | /     pub fn commitment(&self) -> &Commitment {
[INFO] [stderr] 124 | |         &self.commitment
[INFO] [stderr] 125 | |     }
[INFO] [stderr]     | |_____^
[INFO] [stderr] 
[INFO] [stderr] warning: Missing code example in this documentation
[INFO] [stderr]    --> src/tree.rs:127:5
[INFO] [stderr]     |
[INFO] [stderr] 127 | /     pub fn leaf_depth(&self) -> usize {
[INFO] [stderr] 128 | |         Index::depth_for_size(self.leaves().len())
[INFO] [stderr] 129 | |     }
[INFO] [stderr]     | |_____^
[INFO] [stderr] 
[INFO] [stderr] warning: Missing code example in this documentation
[INFO] [stderr]    --> src/tree.rs:131:5
[INFO] [stderr]     |
[INFO] [stderr] 131 | /     pub fn leaves(&self) -> &Container {
[INFO] [stderr] 132 | |         &self.leaves
[INFO] [stderr] 133 | |     }
[INFO] [stderr]     | |_____^
[INFO] [stderr] 
[INFO] [stderr] warning: Missing code example in this documentation
[INFO] [stderr]    --> src/tree.rs:135:5
[INFO] [stderr]     |
[INFO] [stderr] 135 | /     pub fn leaf(&self, index: usize) -> Container::Leaf {
[INFO] [stderr] 136 | |         self.leaves.leaf(index)
[INFO] [stderr] 137 | |     }
[INFO] [stderr]     | |_____^
[INFO] [stderr] 
[INFO] [stderr] warning: Missing code example in this documentation
[INFO] [stderr]    --> src/tree.rs:139:5
[INFO] [stderr]     |
[INFO] [stderr] 139 | /     pub fn node_hash(&self, index: Index) -> Hash {
[INFO] [stderr] 140 | |         if index.as_index() < self.nodes.len() {
[INFO] [stderr] 141 | |             self.nodes[index.as_index()].clone()
[INFO] [stderr] 142 | |         } else {
[INFO] [stderr] ...   |
[INFO] [stderr] 153 | |         }
[INFO] [stderr] 154 | |     }
[INFO] [stderr]     | |_____^
[INFO] [stderr] 
[INFO] [stderr] warning: Missing code example in this documentation
[INFO] [stderr]    --> src/tree.rs:156:5
[INFO] [stderr]     |
[INFO] [stderr] 156 | /     pub fn open(&self, indices: &[usize]) -> Result<Proof> {
[INFO] [stderr] 157 | |         let indices = self.commitment().sort_indices(indices)?;
[INFO] [stderr] 158 | |         let proof_indices: Vec<usize> = indices.iter().map(|i| i.offset()).collect();
[INFO] [stderr] 159 | |         let mut indices: VecDeque<Index> = indices.into_iter().collect();
[INFO] [stderr] ...   |
[INFO] [stderr] 184 | |         Proof::from_hashes(self.commitment(), &proof_indices, &hashes)
[INFO] [stderr] 185 | |     }
[INFO] [stderr]     | |_____^
[INFO] [stderr] 
[INFO] [stderr] warning: Missing code example in this documentation
[INFO] [stderr]   --> src/vector_commitment.rs:1:1
[INFO] [stderr]    |
[INFO] [stderr] 1  | / use crate::{Commitment, Result, Tree};
[INFO] [stderr] 2  | | use std::prelude::v1::*;
[INFO] [stderr] 3  | | use zkp_hash::{Hash, Hashable};
[INFO] [stderr] 4  | |
[INFO] [stderr] ...  |
[INFO] [stderr] 66 | |     }
[INFO] [stderr] 67 | | }
[INFO] [stderr]    | |_^
[INFO] [stderr] 
[INFO] [stderr] warning: Missing code example in this documentation
[INFO] [stderr]   --> src/vector_commitment.rs:8:1
[INFO] [stderr]    |
[INFO] [stderr] 8  | / pub trait VectorCommitment
[INFO] [stderr] 9  | | where
[INFO] [stderr] 10 | |     Self: Sync + Sized,
[INFO] [stderr] 11 | |     Self::Leaf: Sync + Hashable,
[INFO] [stderr] ...  |
[INFO] [stderr] 31 | |     }
[INFO] [stderr] 32 | | }
[INFO] [stderr]    | |_^
[INFO] [stderr] 
[INFO] [stderr] warning: Missing code example in this documentation
[INFO] [stderr]   --> src/vector_commitment.rs:13:5
[INFO] [stderr]    |
[INFO] [stderr] 13 |     type Leaf;
[INFO] [stderr]    |     ^^^^^^^^^^
[INFO] [stderr] 
[INFO] [stderr] warning: Missing code example in this documentation
[INFO] [stderr]   --> src/vector_commitment.rs:15:5
[INFO] [stderr]    |
[INFO] [stderr] 15 |     fn len(&self) -> usize;
[INFO] [stderr]    |     ^^^^^^^^^^^^^^^^^^^^^^^
[INFO] [stderr] 
[INFO] [stderr] warning: Missing code example in this documentation
[INFO] [stderr]   --> src/vector_commitment.rs:17:5
[INFO] [stderr]    |
[INFO] [stderr] 17 | /     fn is_empty(&self) -> bool {
[INFO] [stderr] 18 | |         self.len() == 0
[INFO] [stderr] 19 | |     }
[INFO] [stderr]    | |_____^
[INFO] [stderr] 
[INFO] [stderr] warning: Missing code example in this documentation
[INFO] [stderr]   --> src/vector_commitment.rs:21:5
[INFO] [stderr]    |
[INFO] [stderr] 21 |     fn leaf(&self, index: usize) -> Self::Leaf;
[INFO] [stderr]    |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[INFO] [stderr] 
[INFO] [stderr] warning: Missing code example in this documentation
[INFO] [stderr]   --> src/vector_commitment.rs:23:5
[INFO] [stderr]    |
[INFO] [stderr] 23 | /     fn leaf_hash(&self, index: usize) -> Hash {
[INFO] [stderr] 24 | |         self.leaf(index).hash()
[INFO] [stderr] 25 | |     }
[INFO] [stderr]    | |_____^
[INFO] [stderr] 
[INFO] [stderr] warning: Missing code example in this documentation
[INFO] [stderr]   --> src/vector_commitment.rs:27:5
[INFO] [stderr]    |
[INFO] [stderr] 27 | /     fn commit(self) -> Result<(Commitment, Tree<Self>)> {
[INFO] [stderr] 28 | |         let tree = Tree::from_leaves(self)?;
[INFO] [stderr] 29 | |         let commitment = tree.commitment().clone();
[INFO] [stderr] 30 | |         Ok((commitment, tree))
[INFO] [stderr] 31 | |     }
[INFO] [stderr]    | |_____^
[INFO] [stderr] 
[INFO] [stderr] warning: Missing code example in this documentation
[INFO] [stderr]   --> src/vector_commitment.rs:36:1
[INFO] [stderr]    |
[INFO] [stderr] 36 | / impl<Leaf: Hashable + Clone + Sync> VectorCommitment for Vec<Leaf> {
[INFO] [stderr] 37 | |     type Leaf = Leaf;
[INFO] [stderr] 38 | |
[INFO] [stderr] 39 | |     fn len(&self) -> usize {
[INFO] [stderr] ...  |
[INFO] [stderr] 49 | |     }
[INFO] [stderr] 50 | | }
[INFO] [stderr]    | |_^
[INFO] [stderr] 
[INFO] [stderr] warning: Missing code example in this documentation
[INFO] [stderr]   --> src/vector_commitment.rs:37:5
[INFO] [stderr]    |
[INFO] [stderr] 37 |     type Leaf = Leaf;
[INFO] [stderr]    |     ^^^^^^^^^^^^^^^^^
[INFO] [stderr] 
[INFO] [stderr] warning: Missing code example in this documentation
[INFO] [stderr]   --> src/vector_commitment.rs:39:5
[INFO] [stderr]    |
[INFO] [stderr] 39 | /     fn len(&self) -> usize {
[INFO] [stderr] 40 | |         Self::len(self)
[INFO] [stderr] 41 | |     }
[INFO] [stderr]    | |_____^
[INFO] [stderr] 
[INFO] [stderr] warning: Missing code example in this documentation
[INFO] [stderr]   --> src/vector_commitment.rs:43:5
[INFO] [stderr]    |
[INFO] [stderr] 43 | /     fn leaf(&self, index: usize) -> Self::Leaf {
[INFO] [stderr] 44 | |         self[index].clone()
[INFO] [stderr] 45 | |     }
[INFO] [stderr]    | |_____^
[INFO] [stderr] 
[INFO] [stderr] warning: Missing code example in this documentation
[INFO] [stderr]   --> src/vector_commitment.rs:47:5
[INFO] [stderr]    |
[INFO] [stderr] 47 | /     fn leaf_hash(&self, index: usize) -> Hash {
[INFO] [stderr] 48 | |         self[index].hash()
[INFO] [stderr] 49 | |     }
[INFO] [stderr]    | |_____^
[INFO] [stderr] 
[INFO] [stderr] warning: Missing code example in this documentation
[INFO] [stderr]   --> src/result.rs:17:1
[INFO] [stderr]    |
[INFO] [stderr] 17 | / impl fmt::Display for Error {
[INFO] [stderr] 18 | |     fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
[INFO] [stderr] 19 | |         use Error::*;
[INFO] [stderr] 20 | |         match *self {
[INFO] [stderr] ...  |
[INFO] [stderr] 29 | |     }
[INFO] [stderr] 30 | | }
[INFO] [stderr]    | |_^
[INFO] [stderr] 
[INFO] [stderr] warning: Missing code example in this documentation
[INFO] [stderr]   --> src/result.rs:18:5
[INFO] [stderr]    |
[INFO] [stderr] 18 | /     fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
[INFO] [stderr] 19 | |         use Error::*;
[INFO] [stderr] 20 | |         match *self {
[INFO] [stderr] 21 | |             TreeToLarge => write!(f, "Tree too large"),
[INFO] [stderr] ...  |
[INFO] [stderr] 28 | |         }
[INFO] [stderr] 29 | |     }
[INFO] [stderr]    | |_____^
[INFO] [stderr] 
[INFO] [stderr] warning: Missing code example in this documentation
[INFO] [stderr]   --> src/result.rs:33:1
[INFO] [stderr]    |
[INFO] [stderr] 33 | / impl error::Error for Error {
[INFO] [stderr] 34 | |     fn source(&self) -> Option<&(dyn error::Error + 'static)> {
[INFO] [stderr] 35 | |         match *self {
[INFO] [stderr] 36 | |             _ => None,
[INFO] [stderr] 37 | |         }
[INFO] [stderr] 38 | |     }
[INFO] [stderr] 39 | | }
[INFO] [stderr]    | |_^
[INFO] [stderr] 
[INFO] [stderr] warning: Missing code example in this documentation
[INFO] [stderr]   --> src/result.rs:34:5
[INFO] [stderr]    |
[INFO] [stderr] 34 | /     fn source(&self) -> Option<&(dyn error::Error + 'static)> {
[INFO] [stderr] 35 | |         match *self {
[INFO] [stderr] 36 | |             _ => None,
[INFO] [stderr] 37 | |         }
[INFO] [stderr] 38 | |     }
[INFO] [stderr]    | |_____^
[INFO] [stderr] 
[INFO] [stderr]     Finished dev [unoptimized + debuginfo] target(s) in 22.06s
[INFO] running `"docker" "inspect" "c85fcfb57c3ef7292dd2eb64d1ab000daebbdd1319a39bb84f0755e79bb30313"`
[INFO] running `"docker" "rm" "-f" "c85fcfb57c3ef7292dd2eb64d1ab000daebbdd1319a39bb84f0755e79bb30313"`
[INFO] [stdout] c85fcfb57c3ef7292dd2eb64d1ab000daebbdd1319a39bb84f0755e79bb30313