Fix conversion bug for exp operation.

This commit is contained in:
chriseth
2020-07-27 10:44:42 +02:00
parent 42063f2158
commit 2c574af45b
3 changed files with 27 additions and 4 deletions
@@ -0,0 +1,11 @@
contract C {
function f() public pure returns (uint16 x) {
// tests that ``e`` is not converted to uint8
// right before the exp
uint16 e = 0x100;
uint8 b = 0x2;
return b**e;
}
}
// ----
// f() -> 0x00