diff options
Diffstat (limited to 'CompilerContext.cpp')
-rw-r--r-- | CompilerContext.cpp | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/CompilerContext.cpp b/CompilerContext.cpp index 5d10a5f9..29e98eab 100644 --- a/CompilerContext.cpp +++ b/CompilerContext.cpp @@ -95,6 +95,11 @@ unsigned CompilerContext::baseToCurrentStackOffset(unsigned _baseOffset) const return _baseOffset + m_asm.deposit(); } +unsigned CompilerContext::currentToBaseStackOffset(unsigned _offset) const +{ + return -baseToCurrentStackOffset(-_offset); +} + u256 CompilerContext::getStorageLocationOfVariable(const Declaration& _declaration) const { auto it = m_stateVariables.find(&_declaration); |