()
| 847 | .push(outer_id, LocalDecl::CDecl { name: (), bi: (), ty: sort0() }); |
| 848 | let saved = tc.lctx.len(); |
| 849 | |
| 850 | assert!(tc.infer(&expr).is_err(), "{kind} body must fail"); |
| 851 | assert_eq!( |
| 852 | tc.lctx.len(), |
| 853 | saved, |
| 854 | "{kind} inference leaked a binder local after error" |
| 855 | ); |
| 856 | assert!( |
| 857 | tc.lctx.find(outer_id).is_some(), |
| 858 | "{kind} inference damaged the enclosing local context" |
| 859 | ); |
| 860 | } |
| 861 | } |
| 862 |