diff --git a/macros/src/codegen/shared_resources.rs b/macros/src/codegen/shared_resources.rs index aa50dccb6e..b27c827c23 100644 --- a/macros/src/codegen/shared_resources.rs +++ b/macros/src/codegen/shared_resources.rs @@ -69,7 +69,7 @@ pub fn codegen( let ptr = quote!( #(#cfgs)* - (&mut *#mangled_name.get_mut()).as_mut_ptr() + #mangled_name.get_mut() as *mut _ ); let ceiling = match analysis.ownerships.get(name) {