mirror of
https://github.com/pezkuwichain/revive.git
synced 2026-04-23 01:28:01 +00:00
3232382d96
Signed-off-by: xermicus <cyrill@parity.io>
34 lines
734 B
Solidity
34 lines
734 B
Solidity
// SPDX-License-Identifier: MIT
|
|
|
|
pragma solidity ^0.8;
|
|
|
|
/* runner.json
|
|
{
|
|
"differential": false,
|
|
"actions": [
|
|
{
|
|
"Instantiate": {
|
|
"code": {
|
|
"Solidity": {
|
|
"contract": "BlockHash"
|
|
}
|
|
},
|
|
"data": "4545454545454545454545454545454545454545454545454545454545454545"
|
|
}
|
|
}
|
|
]
|
|
}
|
|
*/
|
|
|
|
contract BlockHash {
|
|
constructor(bytes32 expected) payable {
|
|
assert(blockhash(0) == expected);
|
|
assert(blockhash(1) == 0);
|
|
assert(
|
|
blockhash(
|
|
0xffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff
|
|
) == 0
|
|
);
|
|
}
|
|
}
|