Refactoring: use typed versions of args getters (#7262)

* Replace uses of get_unlabeled_kw_arg with _typed version

Signed-off-by: Nick Cameron <nrc@ncameron.org>

* Remove more untyped arg getters

Signed-off-by: Nick Cameron <nrc@ncameron.org>

---------

Signed-off-by: Nick Cameron <nrc@ncameron.org>
This commit is contained in:
Nick Cameron
2025-05-29 16:48:47 +12:00
committed by GitHub
parent c4d2e33a99
commit 87e3588ceb
18 changed files with 84 additions and 96 deletions

View File

@ -63,7 +63,7 @@ pub async fn fillet(exec_state: &mut ExecState, args: Args) -> Result<KclValue,
let solid = args.get_unlabeled_kw_arg_typed("solid", &RuntimeType::solid(), exec_state)?;
let radius: TyF64 = args.get_kw_arg_typed("radius", &RuntimeType::length(), exec_state)?;
let tolerance: Option<TyF64> = args.get_kw_arg_opt_typed("tolerance", &RuntimeType::length(), exec_state)?;
let tags = args.kw_arg_array_and_source::<EdgeReference>("tags")?;
let tags = args.kw_arg_edge_array_and_source("tags")?;
let tag = args.get_kw_arg_opt("tag")?;
// Run the function.