Update lower.rs

This commit is contained in:
Shunsuke Shibayama 2022-12-26 16:43:30 +09:00
parent f3f1bb9ef9
commit 7d458549be

View file

@ -898,7 +898,10 @@ impl ASTLowerer {
Type::FreeVar(fv) if fv.is_unbound() => { Type::FreeVar(fv) if fv.is_unbound() => {
fv.get_sub().unwrap().return_t().unwrap().clone() fv.get_sub().unwrap().return_t().unwrap().clone()
} }
other => todo!("{other:?}"), other => {
log!(err "todo: {other}");
return unreachable_error!(LowerErrors, LowerError, self.ctx);
},
}; };
let arg_t = call.args.get(0).unwrap().ref_t(); let arg_t = call.args.get(0).unwrap().ref_t();
self.ctx.sub_unify(arg_t, &ret_t, call.loc(), None)?; self.ctx.sub_unify(arg_t, &ret_t, call.loc(), None)?;