Removed all implicit logging. Fixed gas issues and jump errors

This commit is contained in:
obscuren
2014-11-11 22:51:26 +01:00
parent 75ee3b3f08
commit 6c9e503eb8
24 changed files with 3871 additions and 225 deletions

View File

@ -46,6 +46,7 @@ var (
gas = flag.String("gas", "1000000", "gas amount")
price = flag.String("price", "0", "gas price")
dump = flag.Bool("dump", false, "dump state after run")
data = flag.String("data", "", "data")
)
func perr(v ...interface{}) {
@ -66,7 +67,7 @@ func main() {
tstart := time.Now()
env := NewVmEnv()
ret, _, e := closure.Call(vm.New(env, vm.DebugVmTy), nil)
ret, _, e := closure.Call(vm.New(env, vm.DebugVmTy), ethutil.Hex2Bytes(*data))
logger.Flush()
if e != nil {
@ -110,7 +111,7 @@ func (VmEnv) GasLimit() *big.Int { return nil }
func (VmEnv) Difficulty() *big.Int { return nil }
func (VmEnv) Value() *big.Int { return nil }
func (self *VmEnv) State() *state.State { return self.state }
func (VmEnv) AddLog(state.Log) {}
func (VmEnv) AddLog(*state.Log) {}
func (VmEnv) Transfer(from, to vm.Account, amount *big.Int) error {
return nil
}