mirror of
https://github.com/ethereum/solidity
synced 2023-10-03 13:03:40 +00:00
Disallow conversions between bytesX and uintY of different size.
This commit is contained in:
committed by
chriseth
parent
76fc4f8e00
commit
5c59d56335
@@ -3859,19 +3859,6 @@ BOOST_AUTO_TEST_CASE(conditional_with_all_types)
|
||||
CHECK_SUCCESS(text);
|
||||
}
|
||||
|
||||
BOOST_AUTO_TEST_CASE(index_access_for_bytes)
|
||||
{
|
||||
char const* text = R"(
|
||||
contract C {
|
||||
bytes20 x;
|
||||
function f(bytes16 b) public {
|
||||
b[uint(x[2])];
|
||||
}
|
||||
}
|
||||
)";
|
||||
CHECK_SUCCESS(text);
|
||||
}
|
||||
|
||||
BOOST_AUTO_TEST_CASE(uint7_and_uintM_as_identifier)
|
||||
{
|
||||
char const* text = R"(
|
||||
|
||||
Reference in New Issue
Block a user