hardhat-vscode icon indicating copy to clipboard operation
hardhat-vscode copied to clipboard

Constructor is included in the list of references for a contract

Open fvictorio opened this issue 2 years ago • 1 comments
trafficstars

Given this code:

contract Foo {
  constructor () {}
}

contract Bar {
  function f() public {
    Foo foo = new Foo();
  }
}

If you find all the references to Foo, the constructor of the contract will be listed as one.

In a somewhat equivalent typescript example:

class Foo {
  constructor() {}
}

const foo: Foo = new Foo();

The constructor is not included.

fvictorio avatar Jan 16 '23 12:01 fvictorio