Unit: squash NPE on invalid class declarations