Introduce use-dependency amalgamation. We now have:
- `use standard;` (bring in a set of standard and external dependencies) - `use common;` (bring in a low-level subset of this crate; basically anything that itself requires only `use standard;`) And, from an external create: - `use ethcore_util::*;` (bring in the entirety of this module and the standard dependencies)
This commit is contained in:
parent
d7fe922425
commit
2b90f7d03a
7
src/common.rs
Normal file
7
src/common.rs
Normal file
@ -0,0 +1,7 @@
|
||||
pub use standard::*;
|
||||
pub use error::*;
|
||||
pub use hash::*;
|
||||
pub use uint::*;
|
||||
pub use bytes::*;
|
||||
pub use vector::*;
|
||||
pub use sha3::*;
|
17
src/lib.rs
17
src/lib.rs
@ -48,6 +48,8 @@ extern crate secp256k1;
|
||||
extern crate arrayvec;
|
||||
extern crate elastic_array;
|
||||
|
||||
pub mod standard;
|
||||
pub mod common;
|
||||
pub mod error;
|
||||
pub mod hash;
|
||||
pub mod uint;
|
||||
@ -68,4 +70,19 @@ pub mod heapsizeof;
|
||||
pub mod squeeze;
|
||||
pub mod semantic_version;
|
||||
|
||||
pub use common::*;
|
||||
pub use rlp::*;
|
||||
pub use hashdb::*;
|
||||
pub use memorydb::*;
|
||||
pub use overlaydb::*;
|
||||
pub use math::*;
|
||||
pub use chainfilter::*;
|
||||
pub use crypto::*;
|
||||
pub use triehash::*;
|
||||
pub use trie::*;
|
||||
pub use nibbleslice::*;
|
||||
pub use heapsizeof::*;
|
||||
pub use squeeze::*;
|
||||
pub use semantic_version::*;
|
||||
|
||||
//pub mod network;
|
||||
|
@ -32,7 +32,7 @@
|
||||
|
||||
pub mod rlptraits;
|
||||
pub mod rlperrors;
|
||||
pub mod rlp;
|
||||
pub mod rlpin;
|
||||
pub mod untrusted_rlp;
|
||||
pub mod rlpstream;
|
||||
|
||||
@ -42,7 +42,7 @@ mod tests;
|
||||
pub use self::rlperrors::DecoderError;
|
||||
pub use self::rlptraits::{Decoder, Decodable, View, Stream, Encodable, Encoder};
|
||||
pub use self::untrusted_rlp::{UntrustedRlp, UntrustedRlpIterator, PayloadInfo, Prototype};
|
||||
pub use self::rlp::{Rlp, RlpIterator};
|
||||
pub use self::rlpin::{Rlp, RlpIterator};
|
||||
pub use self::rlpstream::{RlpStream};
|
||||
use super::hash::H256;
|
||||
|
||||
|
21
src/standard.rs
Normal file
21
src/standard.rs
Normal file
@ -0,0 +1,21 @@
|
||||
pub use std::io;
|
||||
pub use std::str;
|
||||
pub use std::fmt;
|
||||
pub use std::slice;
|
||||
|
||||
pub use std::path::Path;
|
||||
pub use std::str::{FromStr};
|
||||
pub use std::io::{Read,Write};
|
||||
pub use std::hash::{Hash, Hasher};
|
||||
pub use std::error::Error as StdError;
|
||||
|
||||
pub use std::ops::*;
|
||||
pub use std::cmp::*;
|
||||
pub use std::cell::*;
|
||||
pub use std::collections::*;
|
||||
|
||||
pub use rustc_serialize::json::Json;
|
||||
pub use rustc_serialize::base64::FromBase64;
|
||||
pub use rustc_serialize::hex::FromHex;
|
||||
|
||||
pub use heapsize::HeapSizeOf;
|
Loading…
Reference in New Issue
Block a user