garbage_function_args.sol 562 B

12345678910111213141516171819202122232425
  1. @program_id("A8A3VYtDN69E72gceahcfVjLbf7m3c1u2RDwnbWgfRAk")
  2. contract c {
  3. function g(address) public {
  4. require(rubbish, "rubbish n'existe pas!");
  5. }
  6. function g(bytes x) public {
  7. x.readUint8(meh);
  8. }
  9. function g() public {
  10. g({x: foo>1});
  11. }
  12. function g(int) external {
  13. this.g(oo);
  14. }
  15. function g(bool) external {
  16. this.g({x: foo>1});
  17. }
  18. }
  19. // ---- Expect: diagnostics ----
  20. // error: 4:11-18: 'rubbish' not found
  21. // error: 7:15-18: 'meh' not found
  22. // error: 10:9-12: 'foo' not found
  23. // error: 13:10-12: 'oo' not found
  24. // error: 16:14-17: 'foo' not found