mirror of
https://github.com/ethereum/solidity
synced 2023-10-03 13:03:40 +00:00
Better error message when using fractional number as array size expressions
This commit is contained in:
committed by
Alex Beregszaszi
parent
cfc4e5dde3
commit
73f17876e9
@@ -4354,7 +4354,7 @@ BOOST_AUTO_TEST_CASE(invalid_array_declaration_with_rational)
|
||||
}
|
||||
}
|
||||
)";
|
||||
CHECK_ERROR(text, TypeError, "Invalid array length, expected integer literal");
|
||||
CHECK_ERROR(text, TypeError, "Array with fractional length specified.");
|
||||
}
|
||||
|
||||
BOOST_AUTO_TEST_CASE(invalid_array_declaration_with_signed_fixed_type)
|
||||
@@ -4366,7 +4366,7 @@ BOOST_AUTO_TEST_CASE(invalid_array_declaration_with_signed_fixed_type)
|
||||
}
|
||||
}
|
||||
)";
|
||||
CHECK_ERROR(text, TypeError, "Invalid array length, expected integer literal");
|
||||
CHECK_ERROR(text, TypeError, "Invalid array length, expected integer literal.");
|
||||
}
|
||||
|
||||
BOOST_AUTO_TEST_CASE(invalid_array_declaration_with_unsigned_fixed_type)
|
||||
@@ -4378,7 +4378,7 @@ BOOST_AUTO_TEST_CASE(invalid_array_declaration_with_unsigned_fixed_type)
|
||||
}
|
||||
}
|
||||
)";
|
||||
CHECK_ERROR(text, TypeError, "Invalid array length, expected integer literal");
|
||||
CHECK_ERROR(text, TypeError, "Invalid array length, expected integer literal.");
|
||||
}
|
||||
|
||||
BOOST_AUTO_TEST_CASE(rational_to_bytes_implicit_conversion)
|
||||
|
||||
Reference in New Issue
Block a user