solidity/test/libsolidity/semanticTests/array/create_memory_byte_array.sol
2020-05-14 12:55:14 +02:00

13 lines
234 B
Solidity

contract C {
function f() public returns (bytes1) {
bytes memory x = new bytes(35);
assert(x.length == 35);
x[34] = "A";
return (x[34]);
}
}
// ====
// compileViaYul: also
// ----
// f() -> "A"