Fix a crash when the first imperfect split branch was invalidated