Added the new invariant checks. There seems to be a few unset locations in the multi-level exit code.