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

Function good_level_comp1

crates/kernel/src/tutorial/basic.rs:214–222  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

212 /// But type is Sort 1 = Type, so Prop : Type is correct.
213 #[test]
214 fn good_level_comp1() {
215 let mut env = KEnv::<Meta>::new();
216 let ty = sort(usucc(uzero())); // Sort 1
217 let val = sort(uimax(usucc(uzero()), uzero())); // Sort (imax 1 0)
218 let (id, c) =
219 mk_defn("levelComp1", 0, vec![], ty, val, ReducibilityHints::Opaque);
220 env.insert(id.clone(), c);
221 check_accepts(&mut env, &id);
222 }
223
224 /// levelComp2 : Sort 2 := Sort (imax 0 1)
225 /// imax 0 1 = max 0 1 = 1 (since second arg is nonzero), so Sort(imax 0 1) = Sort 1 = Type.

Callers

nothing calls this directly

Calls 8

sortFunction · 0.85
usuccFunction · 0.85
uzeroFunction · 0.85
uimaxFunction · 0.85
mk_defnFunction · 0.85
check_acceptsFunction · 0.85
insertMethod · 0.45
cloneMethod · 0.45

Tested by

no test coverage detected