mirror of
https://github.com/ethereum/solidity
synced 2023-10-03 13:03:40 +00:00
16 lines
304 B
Solidity
16 lines
304 B
Solidity
contract C {
|
|
function f(int256 a, uint256 b) public returns (int256) {
|
|
return a << b;
|
|
}
|
|
|
|
function g(int256 a, uint256 b) public returns (int256) {
|
|
return a >> b;
|
|
}
|
|
}
|
|
|
|
// ====
|
|
// compileViaYul: also
|
|
// ----
|
|
// f(int256,uint256): 1, -1 -> 0
|
|
// g(int256,uint256): 1, -1 -> 0
|