PyO3 / pyo3

Rust bindings for the Python interpreter
https://pyo3.rs
Other
11.44k stars 693 forks source link

Add several missing wrappers to PyAnyMethods #4264

Closed xen0n closed 1 week ago

xen0n commented 1 week ago

I discovered these missing bits when I was working on a starlark-rust binding -- I had to forward between Python and Starlark most magic methods but some are missing in PyAnyMethods, for example those for // and %, among a couple of others.

I have consulted the Python C API Number protocol and this seems complete. Please review and thanks for maintaining this great framework!