aboutsummaryrefslogtreecommitdiffstats
path: root/libsolidity/codegen/CompilerUtils.cpp
diff options
context:
space:
mode:
authorVoR0220 <catalanor0220@gmail.com>2016-03-30 04:08:51 +0800
committerVoR0220 <catalanor0220@gmail.com>2016-05-10 00:41:02 +0800
commit4b749fc33335cee2de50e31776ddae1f73649a7b (patch)
treea8f28bbb649a1f4e80845aaef5a9b34c2f6c4f05 /libsolidity/codegen/CompilerUtils.cpp
parent4d283b2b304f9c9a85fb6f03346cc7c9d0054daa (diff)
downloaddexon-solidity-4b749fc33335cee2de50e31776ddae1f73649a7b.tar.gz
dexon-solidity-4b749fc33335cee2de50e31776ddae1f73649a7b.tar.zst
dexon-solidity-4b749fc33335cee2de50e31776ddae1f73649a7b.zip
changed names for Rational Constants and categories
Diffstat (limited to 'libsolidity/codegen/CompilerUtils.cpp')
-rw-r--r--libsolidity/codegen/CompilerUtils.cpp10
1 files changed, 5 insertions, 5 deletions
diff --git a/libsolidity/codegen/CompilerUtils.cpp b/libsolidity/codegen/CompilerUtils.cpp
index 15446978..9efb2c29 100644
--- a/libsolidity/codegen/CompilerUtils.cpp
+++ b/libsolidity/codegen/CompilerUtils.cpp
@@ -345,11 +345,11 @@ void CompilerUtils::convertType(Type const& _typeOnStack, Type const& _targetTyp
break;
case Type::Category::Integer:
case Type::Category::Contract:
- case Type::Category::NumberConstant:
+ case Type::Category::RationalNumber
case Type::Category::FixedPoint:
if (targetTypeCategory == Type::Category::FixedBytes)
{
- solAssert(stackTypeCategory == Type::Category::Integer || stackTypeCategory == Type::Category::NumberConstant,
+ solAssert(stackTypeCategory == Type::Category::Integer || stackTypeCategory == Type::Category::RationalNumber,
"Invalid conversion to FixedBytesType requested.");
// conversion from bytes to string. no need to clean the high bit
// only to shift left because of opposite alignment
@@ -366,7 +366,7 @@ void CompilerUtils::convertType(Type const& _typeOnStack, Type const& _targetTyp
{
solAssert(
stackTypeCategory == Type::Category::Integer ||
- stackTypeCategory == Type::Category::NumberConstant ||
+ stackTypeCategory == Type::Category::RationalNumber ||
stackTypeCategory == Type::Category::FixedPoint,
"Invalid conversion to FixedMxNType requested."
);
@@ -384,9 +384,9 @@ void CompilerUtils::convertType(Type const& _typeOnStack, Type const& _targetTyp
IntegerType addressType(0, IntegerType::Modifier::Address);
IntegerType const& targetType = targetTypeCategory == Type::Category::Integer
? dynamic_cast<IntegerType const&>(_targetType) : addressType;
- if (stackTypeCategory == Type::Category::NumberConstant)
+ if (stackTypeCategory == Type::Category::RationalNumber)
{
- ConstantNumberType const& constType = dynamic_cast<ConstantNumberType const&>(_typeOnStack);
+ RationalNumberType const& constType = dynamic_cast<RationalNumberType const&>(_typeOnStack);
// We know that the stack is clean, we only have to clean for a narrowing conversion
// where cleanup is forced.
if (targetType.numBits() < constType.integerType()->numBits() && _cleanupNeeded)