mirror of
https://github.com/ethereum/solidity
synced 2023-10-03 13:03:40 +00:00
21 lines
506 B
Solidity
21 lines
506 B
Solidity
|
// NOTE: This does not really test copying from storage to ABI directly,
|
||
|
// because it will always copy to memory first.
|
||
|
contract c {
|
||
|
int16[] x;
|
||
|
|
||
|
function test() public returns (int16[] memory) {
|
||
|
x.push(int16(-1));
|
||
|
x.push(int16(-1));
|
||
|
x.push(int16(8));
|
||
|
x.push(int16(-16));
|
||
|
x.push(int16(-2));
|
||
|
x.push(int16(6));
|
||
|
x.push(int16(8));
|
||
|
x.push(int16(-1));
|
||
|
return x;
|
||
|
}
|
||
|
}
|
||
|
|
||
|
// ----
|
||
|
// test() -> 0x20, 0x8, -1, -1, 8, -16, -2, 6, 8, -1
|