MCPcopy Create free account
hub / github.com/argumentcomputer/ix / infer_var

Function infer_var

crates/kernel/src/infer.rs:681–689  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

679
680 #[test]
681 fn infer_var() {
682 let mut env = test_env();
683 let mut tc = TypeChecker::new(&mut env);
684 tc.push_local(sort0());
685 let ty = tc.infer(&AE::var(0, ())).unwrap();
686 // Var(0) has type Sort 0 (the type we pushed)
687 assert_eq!(ty, sort0());
688 tc.pop_local();
689 }
690
691 #[test]
692 fn infer_const() {

Callers

nothing calls this directly

Calls 6

push_localMethod · 0.80
inferMethod · 0.80
pop_localMethod · 0.80
test_envFunction · 0.70
sort0Function · 0.70
varFunction · 0.70

Tested by

no test coverage detected