diff options
author | Alex Beregszaszi <alex@rtfs.hu> | 2018-04-30 21:35:26 +0800 |
---|---|---|
committer | Alex Beregszaszi <alex@rtfs.hu> | 2018-04-30 21:35:26 +0800 |
commit | 548bf2ff2812cc2fe43f60e915fd62ad9f3cbf87 (patch) | |
tree | 7855b9b04e67efae859678489e79bf3d1cdc8b3b /libsolidity | |
parent | c44294d02ddfca52bc93c33593b18e2f91b1f167 (diff) | |
download | dexon-solidity-548bf2ff2812cc2fe43f60e915fd62ad9f3cbf87.tar.gz dexon-solidity-548bf2ff2812cc2fe43f60e915fd62ad9f3cbf87.tar.zst dexon-solidity-548bf2ff2812cc2fe43f60e915fd62ad9f3cbf87.zip |
Remove unused function smallestTypeForLiteral
Diffstat (limited to 'libsolidity')
-rw-r--r-- | libsolidity/ast/Types.cpp | 7 | ||||
-rw-r--r-- | libsolidity/ast/Types.h | 4 |
2 files changed, 0 insertions, 11 deletions
diff --git a/libsolidity/ast/Types.cpp b/libsolidity/ast/Types.cpp index 63724ca0..0ff1dc2e 100644 --- a/libsolidity/ast/Types.cpp +++ b/libsolidity/ast/Types.cpp @@ -1274,13 +1274,6 @@ bool StringLiteralType::isValidUTF8() const return dev::validateUTF8(m_value); } -shared_ptr<FixedBytesType> FixedBytesType::smallestTypeForLiteral(string const& _literal) -{ - if (_literal.length() <= 32) - return make_shared<FixedBytesType>(_literal.length()); - return shared_ptr<FixedBytesType>(); -} - FixedBytesType::FixedBytesType(int _bytes): m_bytes(_bytes) { solAssert( diff --git a/libsolidity/ast/Types.h b/libsolidity/ast/Types.h index 345f84a1..9af333da 100644 --- a/libsolidity/ast/Types.h +++ b/libsolidity/ast/Types.h @@ -502,10 +502,6 @@ class FixedBytesType: public Type public: virtual Category category() const override { return Category::FixedBytes; } - /// @returns the smallest bytes type for the given literal or an empty pointer - /// if no type fits. - static std::shared_ptr<FixedBytesType> smallestTypeForLiteral(std::string const& _literal); - explicit FixedBytesType(int _bytes); virtual bool isImplicitlyConvertibleTo(Type const& _convertTo) const override; |