Fixing compiler and runtime assertions