Fix case of reporting errors with errors disabled

In some cases during type inference we could report errors, even though
type errors were disabled.

Fixes #405.