aboutsummaryrefslogtreecommitdiffstats
path: root/libsolidity/codegen
diff options
context:
space:
mode:
authorYoichi Hirai <i@yoichihirai.com>2016-11-10 00:02:25 +0800
committerYoichi Hirai <i@yoichihirai.com>2016-11-12 00:48:03 +0800
commit20c2ca39922f4230b504888644d04f4bc8d6b8f3 (patch)
tree0adf593efa8f5dae1ee66ed8628cdaaf053fdb68 /libsolidity/codegen
parent4b6e7e0677c9d5de50258fab39ed62e48778ac7a (diff)
downloaddexon-solidity-20c2ca39922f4230b504888644d04f4bc8d6b8f3.tar
dexon-solidity-20c2ca39922f4230b504888644d04f4bc8d6b8f3.tar.gz
dexon-solidity-20c2ca39922f4230b504888644d04f4bc8d6b8f3.tar.bz2
dexon-solidity-20c2ca39922f4230b504888644d04f4bc8d6b8f3.tar.lz
dexon-solidity-20c2ca39922f4230b504888644d04f4bc8d6b8f3.tar.xz
dexon-solidity-20c2ca39922f4230b504888644d04f4bc8d6b8f3.tar.zst
dexon-solidity-20c2ca39922f4230b504888644d04f4bc8d6b8f3.zip
ast, codegen: disallow conversion between different enum types
Diffstat (limited to 'libsolidity/codegen')
-rw-r--r--libsolidity/codegen/CompilerUtils.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/libsolidity/codegen/CompilerUtils.cpp b/libsolidity/codegen/CompilerUtils.cpp
index ad155b13..2f30f53e 100644
--- a/libsolidity/codegen/CompilerUtils.cpp
+++ b/libsolidity/codegen/CompilerUtils.cpp
@@ -348,7 +348,7 @@ void CompilerUtils::convertType(Type const& _typeOnStack, Type const& _targetTyp
}
break;
case Type::Category::Enum:
- solAssert(targetTypeCategory == Type::Category::Integer || targetTypeCategory == Type::Category::Enum, "");
+ solAssert(_targetType == _typeOnStack || targetTypeCategory == Type::Category::Integer, "");
break;
case Type::Category::FixedPoint:
solAssert(false, "Not yet implemented - FixedPointType.");