feat: best-effort type instantiation

This commit is contained in:
Shunsuke Shibayama 2024-04-20 22:51:14 +09:00
parent f6ea1d1d79
commit 1f88084360
13 changed files with 2203 additions and 865 deletions

View file

@ -1218,7 +1218,7 @@ pub(crate) fn filter_func(mut args: ValueArgs, ctx: &Context) -> EvalValueResult
return Err(type_mismatch("Bool", tp, "func"));
}
},
Err(mut err) => {
Err((_res, mut err)) => {
return Err(EvalValueError::from(*err.remove(0).core));
}
}
@ -1272,7 +1272,7 @@ pub(crate) fn map_func(mut args: ValueArgs, ctx: &Context) -> EvalValueResult<Ty
Ok(res) => {
mapped.push(res);
}
Err(mut err) => {
Err((_res, mut err)) => {
return Err(EvalValueError::from(*err.remove(0).core));
}
}