aboutsummaryrefslogtreecommitdiffstats
path: root/Compiler.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'Compiler.cpp')
-rw-r--r--Compiler.cpp6
1 files changed, 3 insertions, 3 deletions
diff --git a/Compiler.cpp b/Compiler.cpp
index 8c5d26f1..601a679a 100644
--- a/Compiler.cpp
+++ b/Compiler.cpp
@@ -292,7 +292,7 @@ bool Compiler::visit(Break const&)
bool Compiler::visit(Return const& _return)
{
//@todo modifications are needed to make this work with functions returning multiple values
- if (Expression* expression = _return.getExpression())
+ if (Expression const* expression = _return.getExpression())
{
ExpressionCompiler::compileExpression(m_context, *expression);
VariableDeclaration const& firstVariable = *_return.getFunctionReturnParameters().getParameters().front();
@@ -307,7 +307,7 @@ bool Compiler::visit(Return const& _return)
bool Compiler::visit(VariableDefinition const& _variableDefinition)
{
- if (Expression* expression = _variableDefinition.getExpression())
+ if (Expression const* expression = _variableDefinition.getExpression())
{
ExpressionCompiler::compileExpression(m_context, *expression);
ExpressionCompiler::appendTypeConversion(m_context,
@@ -322,7 +322,7 @@ bool Compiler::visit(VariableDefinition const& _variableDefinition)
bool Compiler::visit(ExpressionStatement const& _expressionStatement)
{
- Expression& expression = _expressionStatement.getExpression();
+ Expression const& expression = _expressionStatement.getExpression();
ExpressionCompiler::compileExpression(m_context, expression);
// Type::Category category = expression.getType()->getCategory();
for (unsigned i = 0; i < expression.getType()->getSizeOnStack(); ++i)