MCPcopy Create free account
hub / github.com/argotorg/solidity / baseStackOffsetOfVariable

Method baseStackOffsetOfVariable

libsolidity/codegen/CompilerContext.cpp:304–310  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

302}
303
304unsigned CompilerContext::baseStackOffsetOfVariable(Declaration const& _declaration) const
305{
306 auto res = m_localVariables.find(&_declaration);
307 solAssert(res != m_localVariables.end(), "Variable not found on stack.");
308 solAssert(!res->second.empty(), "");
309 return res->second.back();
310}
311
312unsigned CompilerContext::baseToCurrentStackOffset(unsigned _baseOffset) const
313{

Callers 3

visitMethod · 0.80
moveToStackVariableMethod · 0.80
StackVariableMethod · 0.80

Calls 3

findMethod · 0.45
endMethod · 0.45
emptyMethod · 0.45

Tested by

no test coverage detected