contract-shadows-global.sol 413 B

123456789101112131415
  1. function f(int, int) pure {}
  2. function f(int, bool) pure {}
  3. contract C {
  4. function f(int, int) public pure {}
  5. function f(bool) public pure {}
  6. function f(bool, int) public pure {}
  7. function g() public pure {
  8. f(1, 2);
  9. }
  10. }
  11. // ---- Expect: diagnostics ----
  12. // warning: 4:11-12: f is already defined as a function
  13. // note 1:10-11: location of previous definition
  14. // note 2:1-27: location of previous definition