solidity/test/libsolidity/syntaxTests/nameAndTypeResolution/230_creating_contract_within_the_contract.sol

7 lines
253 B
Solidity
Raw Normal View History

contract Test {
function f() public { var x = new Test(); }
}
// ----
// Warning: (42-47): Use of the "var" keyword is deprecated.
// TypeError: (50-58): Circular reference for contract creation (cannot create instance of derived or same contract).