aboutsummaryrefslogtreecommitdiffstats
path: root/core/chain_makers.go
diff options
context:
space:
mode:
authorPéter Szilágyi <peterke@gmail.com>2017-03-06 02:00:01 +0800
committerFelix Lange <fjl@users.noreply.github.com>2017-03-09 22:50:14 +0800
commit567d41d9363706b4b13ce0903804e8acf214af49 (patch)
tree8c091f0385589074573df3f7964c99417c5950ee /core/chain_makers.go
parent3b00a77de57ab2737a7887521c192ce004c721e3 (diff)
downloadgo-tangerine-567d41d9363706b4b13ce0903804e8acf214af49.tar
go-tangerine-567d41d9363706b4b13ce0903804e8acf214af49.tar.gz
go-tangerine-567d41d9363706b4b13ce0903804e8acf214af49.tar.bz2
go-tangerine-567d41d9363706b4b13ce0903804e8acf214af49.tar.lz
go-tangerine-567d41d9363706b4b13ce0903804e8acf214af49.tar.xz
go-tangerine-567d41d9363706b4b13ce0903804e8acf214af49.tar.zst
go-tangerine-567d41d9363706b4b13ce0903804e8acf214af49.zip
all: swap out the C++ ethash to the pure Go one (mining todo)
Diffstat (limited to 'core/chain_makers.go')
-rw-r--r--core/chain_makers.go13
1 files changed, 1 insertions, 12 deletions
diff --git a/core/chain_makers.go b/core/chain_makers.go
index 8b3b015a8..f63496fdc 100644
--- a/core/chain_makers.go
+++ b/core/chain_makers.go
@@ -43,17 +43,6 @@ func MakeChainConfig() *params.ChainConfig {
}
}
-// FakePow is a non-validating proof of work implementation.
-// It returns true from Verify for any block.
-type FakePow struct{}
-
-func (f FakePow) Search(block pow.Block, stop <-chan struct{}, index int) (uint64, []byte) {
- return 0, nil
-}
-func (f FakePow) Verify(block pow.Block) bool { return true }
-func (f FakePow) GetHashrate() int64 { return 0 }
-func (f FakePow) Turbo(bool) {}
-
// So we can deterministically seed different blockchains
var (
canonicalSeed = 1
@@ -256,7 +245,7 @@ func newCanonical(n int, full bool) (ethdb.Database, *BlockChain, error) {
// Initialize a fresh chain with only a genesis block
genesis, _ := WriteTestNetGenesisBlock(db)
- blockchain, _ := NewBlockChain(db, MakeChainConfig(), FakePow{}, evmux, vm.Config{})
+ blockchain, _ := NewBlockChain(db, MakeChainConfig(), pow.FakePow{}, evmux, vm.Config{})
// Create and inject the requested chain
if n == 0 {
return db, blockchain, nil