Skip to content

Commit

Permalink
Rename local variable fns -> op_tbl
Browse files Browse the repository at this point in the history
  • Loading branch information
chfast committed Sep 12, 2019
1 parent a826d56 commit 4edc45d
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions lib/evmone/analysis.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -32,8 +32,8 @@ inline constexpr uint64_t load64be(const unsigned char* data) noexcept

code_analysis analyze(evmc_revision rev, const uint8_t* code, size_t code_size) noexcept
{
const auto& fns = get_op_table(rev);
const auto opx_beginblock_fn = fns[OPX_BEGINBLOCK].fn;
const auto& op_tbl = get_op_table(rev);
const auto opx_beginblock_fn = op_tbl[OPX_BEGINBLOCK].fn;

code_analysis analysis;

Expand Down Expand Up @@ -77,7 +77,7 @@ code_analysis analyze(evmc_revision rev, const uint8_t* code, size_t code_size)
static_cast<int16_t>(analysis.instrs.size() - 1));
}
else
analysis.instrs.emplace_back(fns[opcode].fn);
analysis.instrs.emplace_back(op_tbl[opcode].fn);

auto& instr = analysis.instrs.back();

Expand Down Expand Up @@ -177,7 +177,7 @@ code_analysis analyze(evmc_revision rev, const uint8_t* code, size_t code_size)

// Make sure the last block is terminated.
// TODO: This is not needed if the last instruction is a terminating one.
analysis.instrs.emplace_back(fns[OP_STOP].fn);
analysis.instrs.emplace_back(op_tbl[OP_STOP].fn);

// FIXME: assert(analysis.instrs.size() <= max_instrs_size);

Expand Down

0 comments on commit 4edc45d

Please sign in to comment.