Skip to content

Commit e764067

Browse files
committed
remove last FIXME
1 parent 7c924e9 commit e764067

File tree

1 file changed

+5
-4
lines changed

1 file changed

+5
-4
lines changed

pyo3-macros-backend/src/pyfunction/signature.rs

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -404,10 +404,11 @@ impl<'a> FunctionSignature<'a> {
404404
if let FnArg::Regular(arg) = fn_arg {
405405
arg.default_value = Some(default.clone());
406406
} else {
407-
// FIXME: In what case can this happen? What should the error message be?
408-
bail_spanned!(
409-
default.span() => "todo"
410-
)
407+
unreachable!(
408+
"`Python` and `CancelHandle` are already handled above and `*args`/`**kwargs` are \
409+
parsed and transformed below. Because the have to come last and are only allowed \
410+
once, this has to be a regular argument."
411+
);
411412
}
412413
}
413414
}

0 commit comments

Comments
 (0)