aboutsummaryrefslogtreecommitdiffstats
path: root/ExpressionCompiler.cpp
diff options
context:
space:
mode:
authorChristian <c@ethdev.com>2014-11-01 00:20:27 +0800
committerChristian <c@ethdev.com>2014-11-01 00:20:27 +0800
commit25c0e08bdfd955d8fdc0e7563c718b6fbba6cd1c (patch)
tree78e49ce681d0b9c5ce6d76b7dc6f445d114f918f /ExpressionCompiler.cpp
parenta36db1f2412d700cc8b32f8331be103c73ea90cb (diff)
parentc45495afb96fcd9bf8b3ad965144a3436fc101a5 (diff)
downloaddexon-solidity-25c0e08bdfd955d8fdc0e7563c718b6fbba6cd1c.tar.gz
dexon-solidity-25c0e08bdfd955d8fdc0e7563c718b6fbba6cd1c.tar.zst
dexon-solidity-25c0e08bdfd955d8fdc0e7563c718b6fbba6cd1c.zip
Merge remote-tracking branch 'ethereum/develop' into sol_contractCompiler
Conflicts: libsolidity/AST.cpp libsolidity/AST.h libsolidity/Compiler.cpp libsolidity/Compiler.h libsolidity/NameAndTypeResolver.h libsolidity/Types.cpp solc/main.cpp test/solidityCompiler.cpp
Diffstat (limited to 'ExpressionCompiler.cpp')
-rw-r--r--ExpressionCompiler.cpp12
1 files changed, 6 insertions, 6 deletions
diff --git a/ExpressionCompiler.cpp b/ExpressionCompiler.cpp
index 53d2d95d..003d561a 100644
--- a/ExpressionCompiler.cpp
+++ b/ExpressionCompiler.cpp
@@ -71,10 +71,10 @@ void ExpressionCompiler::endVisit(UnaryOperation& _unaryOperation)
switch (_unaryOperation.getOperator())
{
case Token::NOT: // !
- m_context << eth::Instruction::NOT;
+ m_context << eth::Instruction::ISZERO;
break;
case Token::BIT_NOT: // ~
- m_context << eth::Instruction::BNOT;
+ m_context << eth::Instruction::NOT;
break;
case Token::DELETE: // delete
{
@@ -262,7 +262,7 @@ void ExpressionCompiler::appendAndOrOperatorCode(BinaryOperation& _binaryOperati
_binaryOperation.getLeftExpression().accept(*this);
m_context << eth::Instruction::DUP1;
if (op == Token::AND)
- m_context << eth::Instruction::NOT;
+ m_context << eth::Instruction::ISZERO;
eth::AssemblyItem endLabel = m_context.appendConditionalJump();
_binaryOperation.getRightExpression().accept(*this);
m_context << endLabel;
@@ -274,7 +274,7 @@ void ExpressionCompiler::appendCompareOperatorCode(Token::Value _operator, Type
{
m_context << eth::Instruction::EQ;
if (_operator == Token::NE)
- m_context << eth::Instruction::NOT;
+ m_context << eth::Instruction::ISZERO;
}
else
{
@@ -288,11 +288,11 @@ void ExpressionCompiler::appendCompareOperatorCode(Token::Value _operator, Type
{
case Token::GTE:
m_context << (isSigned ? eth::Instruction::SGT : eth::Instruction::GT)
- << eth::Instruction::NOT;
+ << eth::Instruction::ISZERO;
break;
case Token::LTE:
m_context << (isSigned ? eth::Instruction::SLT : eth::Instruction::LT)
- << eth::Instruction::NOT;
+ << eth::Instruction::ISZERO;
break;
case Token::GT:
m_context << (isSigned ? eth::Instruction::SLT : eth::Instruction::LT);