()
| 790 | |
| 791 | #[test] |
| 792 | fn infer_unknown_const_errors() { |
| 793 | let mut env = test_env(); |
| 794 | let mut tc = TypeChecker::new(&mut env); |
| 795 | let bogus = AE::cnst(mk_id("DoesNotExist"), Box::new([])); |
| 796 | match tc.infer(&bogus) { |
| 797 | Err(TcError::UnknownConst(addr)) => { |
| 798 | assert_eq!(addr, mk_addr("DoesNotExist")); |
| 799 | }, |
| 800 | other => panic!("expected UnknownConst, got {other:?}"), |
| 801 | } |
| 802 | } |
| 803 | |
| 804 | #[test] |
| 805 | fn infer_univ_param_count_mismatch() { |