X-Git-Url: http://git.bitcoin.ninja/index.cgi?a=blobdiff_plain;ds=sidebyside;f=lightning%2Fsrc%2Flib.rs;h=3bcd5d72c64e19c3adf89d5c8580016582e2462c;hb=a27088d6aa00da10ad3191f1b02acb4ec3d6d22e;hp=29fe76b49adb2ffb8a7e3d7ffc945c6575f06cbf;hpb=061d396b074a8d8b2f7d83c316b158749e6dcdb5;p=rust-lightning diff --git a/lightning/src/lib.rs b/lightning/src/lib.rs index 29fe76b4..3bcd5d72 100644 --- a/lightning/src/lib.rs +++ b/lightning/src/lib.rs @@ -94,7 +94,9 @@ pub use std::io; pub use core2::io; #[cfg(not(feature = "std"))] -mod io_extras { +#[doc(hidden)] +/// IO utilities public only for use by in-crate macros. These should not be used externally +pub mod io_extras { use core2::io::{self, Read, Write}; /// A writer which will move data into the void. @@ -154,6 +156,8 @@ mod io_extras { } #[cfg(feature = "std")] +#[doc(hidden)] +/// IO utilities public only for use by in-crate macros. These should not be used externally mod io_extras { pub fn read_to_end(mut d: D) -> Result, ::std::io::Error> { let mut buf = Vec::new(); @@ -165,12 +169,15 @@ mod io_extras { } mod prelude { + #![allow(unused_imports)] + pub use alloc::{vec, vec::Vec, string::String, collections::VecDeque, boxed::Box}; pub use alloc::borrow::ToOwned; pub use alloc::string::ToString; - pub use core::convert::{TryFrom, TryInto}; + pub use core::convert::{AsMut, AsRef, TryFrom, TryInto}; + pub use core::default::Default; pub use core::marker::Sized; pub(crate) use crate::util::hash_tables::*;