diff --git a/ethcore/src/trace/flat.rs b/ethcore/src/trace/flat.rs
index ae3f22050..f9d3b0831 100644
--- a/ethcore/src/trace/flat.rs
+++ b/ethcore/src/trace/flat.rs
@@ -14,6 +14,8 @@
// You should have received a copy of the GNU General Public License
// along with Parity. If not, see .
+//! Flat trace module
+
use trace::BlockTraces;
use super::trace::{Trace, Action, Res};
diff --git a/ethcore/src/types/blockchain_info.rs b/ethcore/src/types/blockchain_info.rs
index 076225b27..4e8634dba 100644
--- a/ethcore/src/types/blockchain_info.rs
+++ b/ethcore/src/types/blockchain_info.rs
@@ -14,6 +14,8 @@
// You should have received a copy of the GNU General Public License
// along with Parity. If not, see .
+//! Blockhain info type definition
+
use util::numbers::*;
use header::BlockNumber;
use ipc::binary::BinaryConvertError;
diff --git a/ethcore/src/types/ids.rs b/ethcore/src/types/ids.rs
index cdab4ee3f..7d5a4c5fc 100644
--- a/ethcore/src/types/ids.rs
+++ b/ethcore/src/types/ids.rs
@@ -18,7 +18,6 @@
use util::hash::H256;
use header::BlockNumber;
-use util::bytes::{FromRawBytes, FromBytesError, ToBytesWithMap, Populatable};
/// Uniquely identifies block.
#[derive(Debug, PartialEq, Clone, Hash, Eq)]
diff --git a/ethcore/src/types/log_entry.rs b/ethcore/src/types/log_entry.rs
index 9017a00ef..7d8dccc6c 100644
--- a/ethcore/src/types/log_entry.rs
+++ b/ethcore/src/types/log_entry.rs
@@ -14,7 +14,7 @@
// You should have received a copy of the GNU General Public License
// along with Parity. If not, see .
-//! Block log.
+//! Log entry type definition.
use util::numbers::*;
use std::ops::Deref;
diff --git a/ethcore/src/types/receipt.rs b/ethcore/src/types/receipt.rs
index c851cb867..b96b34ed4 100644
--- a/ethcore/src/types/receipt.rs
+++ b/ethcore/src/types/receipt.rs
@@ -17,18 +17,14 @@
//! Receipt
use util::numbers::*;
-use std::ops::Deref;
use util::rlp::*;
-use util::Bytes;
use util::HeapSizeOf;
-use util::sha3::*;
use basic_types::LogBloom;
use header::BlockNumber;
use log_entry::{LogEntry, LocalizedLogEntry};
use ipc::binary::BinaryConvertError;
use std::mem;
use std::collections::VecDeque;
-use rustc_serialize::hex::FromHex;
/// Information describing execution of a transaction.
#[derive(Default, Debug, Clone, Binary)]
@@ -107,7 +103,7 @@ pub struct LocalizedReceipt {
#[test]
fn test_basic() {
- let expected = FromHex::from_hex("f90162a02f697d671e9ae4ee24a43c4b0d7e15f1cb4ba6de1561120d43b9a4e8c4a8a6ee83040caeb9010000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000400000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000008000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000200000000000000000000000000000000000000000000000000000000000000000f838f794dcf421d093428b096ca501a7cd1a740855a7976fc0a00000000000000000000000000000000000000000000000000000000000000000").unwrap();
+ let expected = ::rustc_serialize::hex::FromHex::from_hex("f90162a02f697d671e9ae4ee24a43c4b0d7e15f1cb4ba6de1561120d43b9a4e8c4a8a6ee83040caeb9010000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000400000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000008000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000200000000000000000000000000000000000000000000000000000000000000000f838f794dcf421d093428b096ca501a7cd1a740855a7976fc0a00000000000000000000000000000000000000000000000000000000000000000").unwrap();
let r = Receipt::new(
x!("2f697d671e9ae4ee24a43c4b0d7e15f1cb4ba6de1561120d43b9a4e8c4a8a6ee"),
x!(0x40cae),
diff --git a/ethcore/src/types/trace_types/filter.rs b/ethcore/src/types/trace_types/filter.rs
index c1d237ed7..c02a15c03 100644
--- a/ethcore/src/types/trace_types/filter.rs
+++ b/ethcore/src/types/trace_types/filter.rs
@@ -14,6 +14,8 @@
// You should have received a copy of the GNU General Public License
// along with Parity. If not, see .
+//! Trace filters type definitions
+
use std::ops::Range;
use bloomchain::{Filter as BloomFilter, Bloom, Number};
use util::{Address, FixedHash};
diff --git a/ethcore/src/types/trace_types/localized.rs b/ethcore/src/types/trace_types/localized.rs
index db4d05426..334d7b518 100644
--- a/ethcore/src/types/trace_types/localized.rs
+++ b/ethcore/src/types/trace_types/localized.rs
@@ -14,6 +14,8 @@
// You should have received a copy of the GNU General Public License
// along with Parity. If not, see .
+//! Localized traces type definitions
+
use util::H256;
use super::trace::{Action, Res};
use header::BlockNumber;
diff --git a/ethcore/src/types/trace_types/trace.rs b/ethcore/src/types/trace_types/trace.rs
index 9eb6ef5ac..f8fe07360 100644
--- a/ethcore/src/types/trace_types/trace.rs
+++ b/ethcore/src/types/trace_types/trace.rs
@@ -15,6 +15,7 @@
// along with Parity. If not, see .
//! Tracing datatypes.
+
use util::{U256, Bytes, Address, FixedHash};
use util::rlp::*;
use util::sha3::Hashable;
diff --git a/ethcore/src/types/transaction.rs b/ethcore/src/types/transaction.rs
index cde8e2500..71c77ede9 100644
--- a/ethcore/src/types/transaction.rs
+++ b/ethcore/src/types/transaction.rs
@@ -20,7 +20,7 @@ use util::numbers::*;
use std::ops::Deref;
use util::rlp::*;
use util::sha3::*;
-use util::{UtilError, CryptoError, Bytes, HeapSizeOf, Signature, Secret, ec, OutOfBounds};
+use util::{UtilError, CryptoError, Bytes, Signature, Secret, ec};
use std::cell::*;
use error::*;
use evm::Schedule;
@@ -29,8 +29,6 @@ use ethjson;
use ipc::binary::BinaryConvertError;
use std::mem;
use std::collections::VecDeque;
-use rustc_serialize::hex::FromHex;
-use util::crypto::KeyPair;
#[derive(Debug, Clone, PartialEq, Eq, Binary)]
/// Transaction action type.
@@ -320,7 +318,7 @@ impl SignedTransaction {
}
try!(self.sender());
if self.gas < U256::from(self.gas_required(&schedule)) {
- Err(From::from(TransactionError::InvalidGasLimit(OutOfBounds{min: Some(U256::from(self.gas_required(&schedule))), max: None, found: self.gas})))
+ Err(From::from(TransactionError::InvalidGasLimit(::util::OutOfBounds{min: Some(U256::from(self.gas_required(&schedule))), max: None, found: self.gas})))
} else {
Ok(self)
}
@@ -350,7 +348,7 @@ impl Deref for LocalizedTransaction {
#[test]
fn sender_test() {
- let t: SignedTransaction = decode(&FromHex::from_hex("f85f800182520894095e7baea6a6c7c4c2dfeb977efac326af552d870a801ba048b55bfa915ac795c431978d8a6a992b628d557da5ff759b307d495a36649353a0efffd310ac743f371de3b9f7f9cb56c0b28ad43601b4ab949f53faa07bd2c804").unwrap());
+ let t: SignedTransaction = decode(&::rustc_serialize::hex::FromHex::from_hex("f85f800182520894095e7baea6a6c7c4c2dfeb977efac326af552d870a801ba048b55bfa915ac795c431978d8a6a992b628d557da5ff759b307d495a36649353a0efffd310ac743f371de3b9f7f9cb56c0b28ad43601b4ab949f53faa07bd2c804").unwrap());
assert_eq!(t.data, b"");
assert_eq!(t.gas, U256::from(0x5208u64));
assert_eq!(t.gas_price, U256::from(0x01u64));
@@ -364,7 +362,7 @@ fn sender_test() {
#[test]
fn signing() {
- let key = KeyPair::create().unwrap();
+ let key = ::util::crypto::KeyPair::create().unwrap();
let t = Transaction {
action: Action::Create,
nonce: U256::from(42),
diff --git a/ethcore/src/types/tree_route.rs b/ethcore/src/types/tree_route.rs
index 3c4906449..2ad0aa240 100644
--- a/ethcore/src/types/tree_route.rs
+++ b/ethcore/src/types/tree_route.rs
@@ -14,6 +14,8 @@
// You should have received a copy of the GNU General Public License
// along with Parity. If not, see .
+//! Tree route info type definition
+
use util::numbers::H256;
/// Represents a tree route between `from` block and `to` block: