solidity/test/libsolidity/semanticTests/exponentiation/small_exp.sol

18 lines
314 B
Solidity
Raw Normal View History

contract test {
2020-09-15 14:16:30 +00:00
function f() public pure returns (uint r) {
uint32 x;
uint8 y;
assembly {
x := 0xfffffffffe
y := 0x102
}
2020-09-15 14:16:30 +00:00
unchecked { r = x**y; }
return r;
}
}
// ====
// compileViaYul: also
2021-04-23 15:59:01 +00:00
// compileToEwasm: also
// ----
// f() -> 4