WIP
Typechecking now actually fails for (some?) terms that do not type check.