aboutsummaryrefslogtreecommitdiffstats
path: root/Compiler.h
diff options
context:
space:
mode:
Diffstat (limited to 'Compiler.h')
-rw-r--r--Compiler.h8
1 files changed, 8 insertions, 0 deletions
diff --git a/Compiler.h b/Compiler.h
index 60ca00e8..ac794f89 100644
--- a/Compiler.h
+++ b/Compiler.h
@@ -84,6 +84,13 @@ private:
void registerStateVariables(ContractDefinition const& _contract);
void initializeStateVariables(ContractDefinition const& _contract);
+ /// Initialises all memory arrays in the local variables to point to an empty location.
+ void initialiseMemoryArrays(std::vector<VariableDeclaration const*> _variables);
+ /// Pushes the initialised value of the given type to the stack. If the type is a memory
+ /// reference type, allocates memory and pushes the memory pointer.
+ /// Not to be used for storage references.
+ void initialiseInMemory(Type const& _type);
+
virtual bool visit(VariableDeclaration const& _variableDeclaration) override;
virtual bool visit(FunctionDefinition const& _function) override;
virtual bool visit(IfStatement const& _ifStatement) override;
@@ -100,6 +107,7 @@ private:
/// body itself if the last modifier was reached.
void appendModifierOrFunctionCode();
+ void appendStackVariableInitialisation(VariableDeclaration const& _variable);
void compileExpression(Expression const& _expression, TypePointer const& _targetType = TypePointer());
bool const m_optimize;