aboutsummaryrefslogtreecommitdiffstats
path: root/KnownState.h
diff options
context:
space:
mode:
authorchriseth <c@ethdev.com>2015-05-20 06:27:07 +0800
committerchriseth <c@ethdev.com>2015-05-20 06:28:15 +0800
commitd015945a1db28ba55ce674a73091742b781d2d9d (patch)
tree1dfbc3afa30e700181e04b99c9685ff707043024 /KnownState.h
parent3ecd54a83513d8b59b5e27c671a036870cf1bc90 (diff)
downloaddexon-solidity-d015945a1db28ba55ce674a73091742b781d2d9d.tar.gz
dexon-solidity-d015945a1db28ba55ce674a73091742b781d2d9d.tar.zst
dexon-solidity-d015945a1db28ba55ce674a73091742b781d2d9d.zip
Gas estimation taking known state into account.
Diffstat (limited to 'KnownState.h')
-rw-r--r--KnownState.h4
1 files changed, 4 insertions, 0 deletions
diff --git a/KnownState.h b/KnownState.h
index 3505df74..9d28ef21 100644
--- a/KnownState.h
+++ b/KnownState.h
@@ -111,6 +111,8 @@ public:
/// Retrieves the current equivalence class fo the given stack element (or generates a new
/// one if it does not exist yet).
Id stackElement(int _stackHeight, SourceLocation const& _location);
+ /// @returns the stackElement relative to the current stack height.
+ Id relativeStackElement(int _stackOffset, SourceLocation const& _location = SourceLocation());
/// @returns its set of tags if the given expression class is a known tag union; returns a set
/// containing the tag if it is a PushTag expression and the empty set otherwise.
@@ -123,6 +125,8 @@ public:
std::map<int, Id> const& stackElements() const { return m_stackElements; }
ExpressionClasses& expressionClasses() const { return *m_expressionClasses; }
+ std::map<Id, Id> const& storageContent() const { return m_storageContent; }
+
private:
/// Assigns a new equivalence class to the next sequence number of the given stack element.
void setStackElement(int _stackHeight, Id _class);