Skip to main content
4 of 4
edited tags
eth
  • 86.5k
  • 53
  • 287
  • 411

What happens if you call a non-existent function of another contract that has no fallback function in Solidity?

Let's say you call a function at another contract in Solidity:

contractB.doFunction()

It would then match it using the function signature to run the function in contractB. If there's not match, it would run the fallback function.

But if neither exists? What happens? Does it throw an error, or would you just expend the cost of the CALL?