Change gas & related fields to unsigned integer type (#2839)
* Change gas & related fields to unsigned integer type * Implement AddUint64Overflow
This commit is contained in:
committed by
Jack Zampolin
parent
f525717054
commit
6e813ab3a8
+3
-1
@@ -203,8 +203,10 @@ func (c Context) WithConsensusParams(params *abci.ConsensusParams) Context {
|
||||
if params == nil {
|
||||
return c
|
||||
}
|
||||
|
||||
// TODO: Do we need to handle invalid MaxGas values?
|
||||
return c.withValue(contextKeyConsensusParams, params).
|
||||
WithGasMeter(NewGasMeter(params.BlockSize.MaxGas))
|
||||
WithGasMeter(NewGasMeter(uint64(params.BlockSize.MaxGas)))
|
||||
}
|
||||
|
||||
func (c Context) WithChainID(chainID string) Context { return c.withValue(contextKeyChainID, chainID) }
|
||||
|
||||
Reference in New Issue
Block a user