Skip to content

Commit

Permalink
Allow useless conversion (#4838)
Browse files Browse the repository at this point in the history
  • Loading branch information
mejrs authored and davidhewitt committed Jan 11, 2025
1 parent bcdbc93 commit 4b04bb3
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions pyo3-macros-backend/src/quotes.rs
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,7 @@ pub(crate) fn ok_wrap(obj: TokenStream, ctx: &Ctx) -> TokenStream {
let pyo3_path = pyo3_path.to_tokens_spanned(*output_span);
quote_spanned! { *output_span => {
let obj = #obj;
#[allow(clippy::useless_conversion)]
#pyo3_path::impl_::wrap::converter(&obj).wrap(obj).map_err(::core::convert::Into::<#pyo3_path::PyErr>::into)
}}
}
Expand Down

0 comments on commit 4b04bb3

Please sign in to comment.