Skip to content

Commit

Permalink
Merge branch 'feature/tron_solidity_0.7.0' of https://github.com/tron…
Browse files Browse the repository at this point in the history
…protocol/solidity into feature/tron_solidity_0.7.0
  • Loading branch information
yanghang8612 committed May 18, 2021
2 parents e952dea + b99cca3 commit a37b7b9
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 1 deletion.
2 changes: 2 additions & 0 deletions libsolidity/ast/Types.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -3477,6 +3477,7 @@ TypePointer FunctionType::mobileType() const
m_declaration,
m_gasSet,
m_valueSet,
m_tokenSet,
m_bound,
m_saltSet
);
Expand Down Expand Up @@ -3716,6 +3717,7 @@ FunctionTypePointer FunctionType::asBoundFunction() const
m_declaration,
m_gasSet,
m_valueSet,
m_tokenSet,
m_saltSet,
true
);
Expand Down
6 changes: 5 additions & 1 deletion libsolidity/codegen/YulUtilFunctions.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -2083,6 +2083,11 @@ string YulUtilFunctions::validatorFunction(Type const& _type, bool _revertOnFail
switch (_type.category())
{
case Type::Category::Address:
case Type::Category::Contract:
{
templ("condition", "eq(value, " + cleanupFunction(IntegerType(168)) + "(value))");
break;
}
case Type::Category::Integer:
case Type::Category::RationalNumber:
case Type::Category::Bool:
Expand All @@ -2092,7 +2097,6 @@ string YulUtilFunctions::validatorFunction(Type const& _type, bool _revertOnFail
case Type::Category::Struct:
case Type::Category::Mapping:
case Type::Category::FixedBytes:
case Type::Category::Contract:
{
templ("condition", "eq(value, " + cleanupFunction(_type) + "(value))");
break;
Expand Down

0 comments on commit a37b7b9

Please sign in to comment.