mirror of
https://github.com/ethereum/go-ethereum.git
synced 2026-08-19 02:12:23 +00:00
core/vm: doc-suggestions from code review
Co-authored-by: Sina M <1591639+s1na@users.noreply.github.com>
This commit is contained in:
parent
8c582aba36
commit
0572bcdb06
1 changed files with 2 additions and 2 deletions
|
|
@ -249,7 +249,7 @@ func (in *EVMInterpreter) Run(contract *Contract, input []byte, readOnly bool) (
|
||||||
} else if sLen > operation.maxStack {
|
} else if sLen > operation.maxStack {
|
||||||
return nil, &ErrStackOverflow{stackLen: sLen, limit: operation.maxStack}
|
return nil, &ErrStackOverflow{stackLen: sLen, limit: operation.maxStack}
|
||||||
}
|
}
|
||||||
// for tracing: this gas consumption is ignored, so can be done in-line
|
// for tracing: this gas consumption event is emitted below in the debug section.
|
||||||
if contract.Gas < cost {
|
if contract.Gas < cost {
|
||||||
return nil, ErrOutOfGas
|
return nil, ErrOutOfGas
|
||||||
} else {
|
} else {
|
||||||
|
|
@ -282,7 +282,7 @@ func (in *EVMInterpreter) Run(contract *Contract, input []byte, readOnly bool) (
|
||||||
if err != nil {
|
if err != nil {
|
||||||
return nil, fmt.Errorf("%w: %v", ErrOutOfGas, err)
|
return nil, fmt.Errorf("%w: %v", ErrOutOfGas, err)
|
||||||
}
|
}
|
||||||
// for tracing: this gas consumption is ignored, so can be done in-line
|
// for tracing: this gas consumption event is emitted below in the debug section.
|
||||||
if contract.Gas < dynamicCost {
|
if contract.Gas < dynamicCost {
|
||||||
return nil, ErrOutOfGas
|
return nil, ErrOutOfGas
|
||||||
} else {
|
} else {
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue