Skip to content
Kavachकवच

Contracts: How they are checked

● Intermediate3 min

While you develop, every contract is checked. In a release build, public functions' contracts and every invariant are.

kavach run, kavach test, debug buildsevery contract
release buildscontracts of pub functions, and every invariant

A contract must only read values: it can't change anything or use a capability, so checking it never changes what the program does.