aboutsummaryrefslogtreecommitdiffstats
path: root/ExpressionCompiler.cpp
diff options
context:
space:
mode:
authorLefteris Karapetsas <lefteris@refu.co>2015-03-05 00:43:40 +0800
committerLefteris Karapetsas <lefteris@refu.co>2015-03-12 19:53:00 +0800
commitbede2f2ad7eb023018ab2faac17286fdee82b03c (patch)
treeed1b2a2f62a01bc61c29e7adab2a5131da5aa218 /ExpressionCompiler.cpp
parent36fe571576a7e5af91d9f95ff0a2252394720a34 (diff)
downloaddexon-solidity-bede2f2ad7eb023018ab2faac17286fdee82b03c.tar.gz
dexon-solidity-bede2f2ad7eb023018ab2faac17286fdee82b03c.tar.zst
dexon-solidity-bede2f2ad7eb023018ab2faac17286fdee82b03c.zip
More changes towards getting rid of HashXX
Diffstat (limited to 'ExpressionCompiler.cpp')
-rw-r--r--ExpressionCompiler.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/ExpressionCompiler.cpp b/ExpressionCompiler.cpp
index 12926112..91a59b2d 100644
--- a/ExpressionCompiler.cpp
+++ b/ExpressionCompiler.cpp
@@ -131,7 +131,7 @@ void ExpressionCompiler::appendTypeConversion(Type const& _typeOnStack, Type con
// conversion from string to hash. no need to clean the high bit
// only to shift right because of opposite alignment
IntegerType const& targetIntegerType = dynamic_cast<IntegerType const&>(_targetType);
- solAssert(targetIntegerType.isHash(), "Only conversion between String and Hash is allowed.");
+ solAssert(targetIntegerType.isBytes(), "Only conversion between String and Bytes is allowed.");
solAssert(targetIntegerType.getNumBits() == typeOnStack.getNumBytes() * 8, "The size should be the same.");
m_context << (u256(1) << (256 - typeOnStack.getNumBytes() * 8)) << eth::Instruction::SWAP1 << eth::Instruction::DIV;
}
@@ -164,7 +164,7 @@ void ExpressionCompiler::appendTypeConversion(Type const& _typeOnStack, Type con
// only to shift left because of opposite alignment
StaticStringType const& targetStringType = dynamic_cast<StaticStringType const&>(_targetType);
IntegerType const& typeOnStack = dynamic_cast<IntegerType const&>(_typeOnStack);
- solAssert(typeOnStack.isHash(), "Only conversion between String and Hash is allowed.");
+ solAssert(typeOnStack.isBytes(), "Only conversion between String and Bytes is allowed.");
solAssert(typeOnStack.getNumBits() == targetStringType.getNumBytes() * 8, "The size should be the same.");
m_context << (u256(1) << (256 - typeOnStack.getNumBits())) << eth::Instruction::MUL;
}