pub fn check_vitals_w_tc<'t, 'l : 't, 'e : 'l>(
    name : NamePtr<'l>,
    uparams : LevelsPtr<'l>,
    type_ : ExprPtr<'l>,
    tc : &mut Tc<'t, 'l, 'e>
) {
    assert!(name.in_env());
    assert!(uparams.in_env());
    assert!(type_.in_env());
    assert!(uparams.no_dupes(tc));
    assert!(!type_.has_locals(tc));
    let inferred_type = type_.infer(Check, tc);
    inferred_type.ensure_sort(tc);
}
// We reuse the typechecker for definitions, so the inference
// will be a cache hit.
We reuse the typechecker for definitions, so the inference
will be a cache hit.
We reuse the typechecker for definitions so the inference will be a cache hit .
pub fn check_vitals_w_tc<'t, 'l : 't, 'e : 'l>(
    name : NamePtr<'l>,
    uparams : LevelsPtr<'l>,
    type_ : ExprPtr<'l>,
    tc : &mut Tc<'t, 'l, 'e>
) {
    assert!(name.in_env());
    assert!(uparams.in_env());
    assert!(type_.in_env());
    assert!(uparams.no_dupes(tc));
    assert!(!type_.has_locals(tc));
    let inferred_type = type_.infer(Check, tc);
    inferred_type.ensure_sort(tc);
}
pub fn check_vitals_w_tc < ' t , ' l : ' t , ' e : ' l > ( name : NamePtr < ' l > , uparams : LevelsPtr < ' l > , type_ : ExprPtr < ' l > , tc : & mut Tc < ' t , ' l , ' e > ) { assert ! ( name in_env ( ) ) ; assert ! ( uparams in_env ( ) ) ; assert ! ( type_ in_env ( ) ) ; assert ! ( uparams no_dupes ( tc ) ) ; assert ! ( type_ has_locals ( tc ) ) ; let inferred_type = type_ . infer ( Check , tc ) ; inferred_type . ensure_sort ( tc ) ; }
We reuse the typechecker for definitions, so the inference
will be a cache hit.
We reuse the typechecker for definitions so the inference will be a cache hit .
name
NamePtr<'l>
uparams
LevelsPtr<'l>
type_
ExprPtr<'l>
tc
&mut Tc<'t, 'l, 'e>
name
NamePtr<'l>
uparams
LevelsPtr<'l>
type_
ExprPtr<'l>
tc
&mut Tc<'t, 'l, 'e>