Skip to content

Commit

Permalink
Touch up PR 1415
Browse files Browse the repository at this point in the history
  • Loading branch information
dtolnay committed Dec 17, 2024
1 parent b10e1bc commit 55998da
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions macro/src/expand.rs
Original file line number Diff line number Diff line change
Expand Up @@ -1231,10 +1231,10 @@ fn expand_rust_function_shim_super(
};

let mut body = quote_spanned!(span=> #call(#(#vars,)*));
let mut allow_unused_unsafe = quote!();
let mut allow_unused_unsafe = None;
if unsafety.is_some() {
body = quote_spanned!(span=>unsafe { #body });
allow_unused_unsafe = quote_spanned!(span=> #[allow(unused_unsafe)]);
body = quote_spanned!(span=> unsafe { #body });
allow_unused_unsafe = Some(quote_spanned!(span=> #[allow(unused_unsafe)]));
}

quote_spanned! {span=>
Expand Down

0 comments on commit 55998da

Please sign in to comment.