Remove unused function smallestTypeForLiteral

This commit is contained in:
Alex Beregszaszi 2018-04-30 14:35:26 +01:00
parent c44294d02d
commit 548bf2ff28
2 changed files with 0 additions and 11 deletions

View File

@ -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(

View File

@ -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;