Skip to content
This repository has been archived by the owner on Nov 6, 2020. It is now read-only.

Commit

Permalink
Remove to-pod-full feature
Browse files Browse the repository at this point in the history
  • Loading branch information
dvdplm committed Jul 7, 2019
1 parent 1cf8254 commit a57517c
Show file tree
Hide file tree
Showing 6 changed files with 4 additions and 18 deletions.
4 changes: 1 addition & 3 deletions ethcore/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -108,15 +108,13 @@ evm-debug-tests = ["evm-debug", "evm/evm-debug-tests"]
# EVM debug traces are printed.
slow-blocks = []
# Run JSON consensus tests.
json-tests = ["env_logger", "test-helpers", "to-pod-full"]
json-tests = ["env_logger", "test-helpers"]
# Skip JSON consensus tests with pending issues.
ci-skip-tests = []
# Run memory/cpu heavy tests.
test-heavy = []
# Compile test helpers
test-helpers = ["tempdir", "kvdb-rocksdb", "blooms-db"]
# Enables slow 'to-pod-full' method for use in tests and evmbin.
to-pod-full = []

[[bench]]
name = "builtin"
Expand Down
4 changes: 0 additions & 4 deletions ethcore/account-state/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,3 @@ account-db = { path = "../account-db" }
journaldb = { path = "../../util/journaldb" }
parity-bytes = "0.1.0"
rlp_compress = { path = "../../util/rlp-compress" }

[features]
# Enables slow 'to-pod-full' method for use in tests and evmbin.
to-pod-full = []
3 changes: 1 addition & 2 deletions ethcore/account-state/src/state.rs
Original file line number Diff line number Diff line change
Expand Up @@ -791,7 +791,6 @@ impl<B: Backend> State<B> {
}))
}

#[cfg(feature="to-pod-full")]
/// Populate a PodAccount map from this state.
/// Warning this is not for real time use.
/// Use of this method requires FatDB mode to be able
Expand Down Expand Up @@ -830,9 +829,9 @@ impl<B: Backend> State<B> {
/// values of the account to the PodAccount.
/// This function is only intended for use in small tests or with fresh accounts.
/// It requires FatDB.
#[cfg(feature="to-pod-full")]
fn account_to_pod_account(&self, account: &Account, address: &Address) -> Result<PodAccount, Error> {
use ethereum_types::BigEndianHash;
assert!(self.factories.trie.is_fat());

let mut pod_storage = BTreeMap::new();
let addr_hash = account.address_hash(address);
Expand Down
5 changes: 0 additions & 5 deletions ethcore/src/client/evm_test_client.rs
Original file line number Diff line number Diff line change
Expand Up @@ -78,14 +78,9 @@ fn no_dump_state(_: &State<state_db::StateDB>) -> Option<PodState> {
None
}

#[cfg(feature = "to-pod-full")]
fn dump_state(state: &State<state_db::StateDB>) -> Option<PodState> {
state.to_pod_full().ok()
}
#[cfg(not(feature = "to-pod-full"))]
fn dump_state(_: &State<state_db::StateDB>) -> Option<PodState> {
None
}

impl<'a> fmt::Debug for EvmTestClient<'a> {
fn fmt(&self, fmt: &mut fmt::Formatter) -> fmt::Result {
Expand Down
2 changes: 0 additions & 2 deletions ethcore/src/executive_state.rs
Original file line number Diff line number Diff line change
Expand Up @@ -274,7 +274,6 @@ mod tests {
use trace::{FlatTrace, TraceError, trace};
use evm::CallType;
use pod::{self, PodAccount};
#[cfg(feature="to-pod-full")]
use pod::PodState;
use executive_state::ExecutiveState;
use account_state::{Account, CleanupMode};
Expand Down Expand Up @@ -1653,7 +1652,6 @@ mod tests {
})).as_ref());
}

#[cfg(feature="to-pod-full")]
#[test]
fn should_get_full_pod_storage_values() {
use trie::{TrieFactory, TrieSpec};
Expand Down
4 changes: 2 additions & 2 deletions evmbin/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ path = "./src/main.rs"
common-types = { path = "../ethcore/types" }
docopt = "1.0"
env_logger = "0.5"
ethcore = { path = "../ethcore", features = ["test-helpers", "json-tests", "to-pod-full"] }
ethcore = { path = "../ethcore", features = ["test-helpers", "json-tests"] }
ethereum-types = "0.6.0"
ethjson = { path = "../json" }
evm = { path = "../ethcore/evm" }
Expand All @@ -23,7 +23,7 @@ rustc-hex = "1.0"
serde = "1.0"
serde_derive = "1.0"
serde_json = "1.0"
account-state = { path = "../ethcore/account-state", features = ["to-pod-full"] }
account-state = { path = "../ethcore/account-state" }
trace = { path = "../ethcore/trace" }
vm = { path = "../ethcore/vm" }

Expand Down

0 comments on commit a57517c

Please sign in to comment.