Change bytes to unsigned in FixedBytesType

This commit is contained in:
daniel
2018-05-03 23:11:34 +01:00
committed by Alex Beregszaszi
parent b34428249a
commit aa1542a9e1
3 changed files with 7 additions and 8 deletions
+2 -3
View File
@@ -599,8 +599,7 @@ FixedPointType::FixedPointType(unsigned _totalBits, unsigned _fractionalDigits,
m_totalBits(_totalBits), m_fractionalDigits(_fractionalDigits), m_modifier(_modifier)
{
solAssert(
8 <= m_totalBits && m_totalBits <= 256 && m_totalBits % 8 == 0 &&
0 <= m_fractionalDigits && m_fractionalDigits <= 80,
8 <= m_totalBits && m_totalBits <= 256 && m_totalBits % 8 == 0 && m_fractionalDigits <= 80,
"Invalid bit number(s) for fixed type: " +
dev::toString(_totalBits) + "x" + dev::toString(_fractionalDigits)
);
@@ -1264,7 +1263,7 @@ bool StringLiteralType::isValidUTF8() const
return dev::validateUTF8(m_value);
}
FixedBytesType::FixedBytesType(int _bytes): m_bytes(_bytes)
FixedBytesType::FixedBytesType(unsigned _bytes): m_bytes(_bytes)
{
solAssert(
m_bytes > 0 && m_bytes <= 32,