fix GlacierMuir to MuirGlacier typo

This commit is contained in:
andri lim 2020-04-12 18:13:22 +07:00
parent 5ca7370407
commit d2b0ca62b2
No known key found for this signature in database
GPG Key ID: 31702AE10541E6B9
2 changed files with 5 additions and 5 deletions

View File

@ -141,13 +141,13 @@ template calcDifficultyByzantium*(timeStamp: EthTime, parent: BlockHeader): Diff
template calcDifficultyConstantinople*(timeStamp: EthTime, parent: BlockHeader): DifficultyInt =
makeDifficultyCalculator(5_000_000, timeStamp, parent)
template calcDifficultyGlacierMuir*(timeStamp: EthTime, parent: BlockHeader): DifficultyInt =
template calcDifficultyMuirGlacier*(timeStamp: EthTime, parent: BlockHeader): DifficultyInt =
makeDifficultyCalculator(9_000_000, timeStamp, parent)
func calcDifficulty*(c: ChainConfig, timeStamp: EthTime, parent: BlockHeader): DifficultyInt =
let next = parent.blockNumber + bigOne
if next >= c.muirGlacierBlock:
result = calcDifficultyGlacierMuir(timeStamp, parent)
result = calcDifficultyMuirGlacier(timeStamp, parent)
elif next >= c.constantinopleBlock:
result = calcDifficultyConstantinople(timeStamp, parent)
elif next >= c.byzantiumBlock:

View File

@ -70,9 +70,9 @@ proc difficultyMain*() =
ropstenConfig.calcDifficulty(timeStamp, parent)
suite "DifficultyTest":
runTests("EIP2384_random_to20M", true, calcDifficultyGlacierMuir)
runTests("EIP2384_random", true, calcDifficultyGlacierMuir)
runTests("EIP2384", true, calcDifficultyGlacierMuir)
runTests("EIP2384_random_to20M", true, calcDifficultyMuirGlacier)
runTests("EIP2384_random", true, calcDifficultyMuirGlacier)
runTests("EIP2384", true, calcDifficultyMuirGlacier)
runTests("Byzantium", true, calcDifficultyByzantium)
runTests("Constantinople", true, calcDifficultyConstantinople)
runTests("Homestead", true, calcDifficultyHomestead)