Avoid hanging on to old unfoldings; fixes #4367 (compiler space regression)