a23b5b5910
These macros now support specifying an argument list: `py_fn!(myfn(myarg: i32))` will expect `myfn` to be a function with the signature: `fn myfn<'p>(py: Python<'p>, myarg: i32) -> PyResult<'p, _>` It can called from python as `myfn(1)` or using keyword arguments: `myfn(myarg=1)`. If no parameter list is specified (`py_fn!(myfn)`), the expected signature now includes the keyword arguments: `fn run<'p>(py: Python<'p>, args: &PyTuple<'p>, kwargs: Option<&PyDict<'p>>)` Due to the additional `kwargs` argument, this is a [breaking-change]. |
||
---|---|---|
.. | ||
.gitignore | ||
Makefile | ||
custom_type.rs | ||
hello.rs | ||
inheritance.rs |