2018-04-12 16:14:48 +00:00
|
|
|
contract A {
|
|
|
|
function a() public pure {
|
|
|
|
}
|
|
|
|
}
|
|
|
|
contract B {
|
2020-06-23 12:14:24 +00:00
|
|
|
constructor(C) {
|
2018-04-12 16:14:48 +00:00
|
|
|
}
|
2018-06-19 19:32:03 +00:00
|
|
|
function b(C) public returns (A) {
|
2018-04-12 16:14:48 +00:00
|
|
|
return new A();
|
|
|
|
}
|
|
|
|
}
|
|
|
|
contract C {
|
|
|
|
B m_b;
|
|
|
|
C m_c;
|
2020-06-23 12:14:24 +00:00
|
|
|
constructor(C other_c) {
|
2018-04-12 16:14:48 +00:00
|
|
|
m_c = other_c;
|
|
|
|
m_b = new B(this);
|
|
|
|
m_b.b(this).a();
|
|
|
|
g(this).f();
|
|
|
|
other_c.f();
|
|
|
|
m_c.f();
|
|
|
|
}
|
|
|
|
function f() public pure {
|
|
|
|
}
|
|
|
|
function g(C) public view returns (C) {
|
|
|
|
return m_c;
|
|
|
|
}
|
|
|
|
}
|
2021-03-12 23:02:36 +00:00
|
|
|
// ----
|