mirror of
https://github.com/ethereum/solidity
synced 2023-10-03 13:03:40 +00:00
16 lines
320 B
Solidity
16 lines
320 B
Solidity
|
contract C {
|
||
|
struct s1 {
|
||
|
uint x;
|
||
|
}
|
||
|
struct s2 {
|
||
|
uint x;
|
||
|
}
|
||
|
function f() public {
|
||
|
s1 memory x;
|
||
|
s2 memory y;
|
||
|
true ? x : y;
|
||
|
}
|
||
|
}
|
||
|
// ----
|
||
|
// TypeError: (165-177): True expression's type struct C.s1 memory doesn't match false expression's type struct C.s2 memory.
|