2020-05-06 15:21:44 +00:00
|
|
|
contract A1 {}
|
2020-06-23 12:14:24 +00:00
|
|
|
contract B1 is A1 { constructor() payable {} }
|
2020-05-06 15:21:44 +00:00
|
|
|
|
2020-06-23 12:14:24 +00:00
|
|
|
contract A2 { constructor() {} }
|
|
|
|
contract B2 is A2 { constructor() payable {} }
|
2020-05-06 15:21:44 +00:00
|
|
|
|
2020-06-23 12:14:24 +00:00
|
|
|
contract B3 { constructor() payable {} }
|
2020-05-06 15:21:44 +00:00
|
|
|
|
|
|
|
contract C {
|
|
|
|
function f() public payable returns (bool) {
|
|
|
|
// Make sure none of these revert.
|
|
|
|
new B1{value: 10}();
|
|
|
|
new B2{value: 10}();
|
|
|
|
new B3{value: 10}();
|
|
|
|
return true;
|
|
|
|
}
|
|
|
|
}
|
|
|
|
// ====
|
|
|
|
// compileViaYul: also
|
|
|
|
// ----
|
|
|
|
// f(), 2000 ether -> true
|