Ethcore crate split part 1 (#6041)

* split out types into separate crate

* split out evm into its own crate
This commit is contained in:
Robert Habermeier
2017-07-12 13:09:17 +02:00
committed by Gav Wood
parent 24c8510932
commit d365281cce
108 changed files with 806 additions and 777 deletions

View File

@@ -15,6 +15,7 @@ serde = "1.0"
serde_derive = "1.0"
ethcore = { path = "../ethcore" }
ethcore-util = { path = "../util" }
evm = { path = "../ethcore/evm" }
[features]
evm-debug = ["ethcore/evm-debug-tests"]

View File

@@ -31,7 +31,7 @@ extern crate rustc_hex;
use self::test::{Bencher, black_box};
use evm::run_vm;
use ethcore::action_params::ActionParams;
use ethcore::evm::action_params::ActionParams;
use ethcore_util::U256;
use rustc_hex::FromHex;

View File

@@ -16,7 +16,7 @@
//! JSON VM output.
use ethcore::{evm, trace};
use ethcore::trace;
use std::collections::HashMap;
use util::{U256, H256, ToPretty};
@@ -94,7 +94,7 @@ impl trace::VMTracer for Informant {
}
fn trace_executed(&mut self, gas_used: U256, stack_push: &[U256], mem_diff: Option<(usize, &[u8])>, store_diff: Option<(U256, U256)>) {
let info = evm::INSTRUCTIONS[self.instruction as usize];
let info = ::evm::INSTRUCTIONS[self.instruction as usize];
println!(
"{{\"pc\":{pc},\"op\":{op},\"opName\":\"{name}\",\"gas\":{gas},\"gasCost\":{gas_cost},\"memory\":{memory},\"stack\":{stack},\"storage\":{storage},\"depth\":{depth}}}",

View File

@@ -25,6 +25,7 @@ extern crate serde;
extern crate serde_derive;
extern crate docopt;
extern crate ethcore_util as util;
extern crate evm;
use std::sync::Arc;
use std::{fmt, fs};
@@ -32,7 +33,7 @@ use docopt::Docopt;
use rustc_hex::FromHex;
use util::{U256, Bytes, Address};
use ethcore::spec;
use ethcore::action_params::ActionParams;
use evm::action_params::ActionParams;
mod vm;
mod display;

View File

@@ -20,7 +20,7 @@ use std::time::{Instant, Duration};
use util::U256;
use ethcore::{trace, spec};
use ethcore::client::{EvmTestClient, EvmTestError};
use ethcore::action_params::ActionParams;
use evm::action_params::ActionParams;
/// VM execution informant
pub trait Informant: trace::VMTracer {