We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 875348d commit 98a4881Copy full SHA for 98a4881
bindgen/codegen/mod.rs
@@ -2747,14 +2747,11 @@ impl CodeGenerator for CompInfo {
2747
{
2748
None
2749
} else {
2750
- // FIXME: When MSRV >= 1.59.0, we can use
2751
- // > const PTR: *const #canonical_ident = ::#prefix::mem::MaybeUninit::uninit().as_ptr();
2752
Some(quote! {
2753
// Use a shared MaybeUninit so that rustc with
2754
// opt-level=0 doesn't take too much stack space,
2755
// see #2218.
2756
- const UNINIT: ::#prefix::mem::MaybeUninit<#canonical_ident> = ::#prefix::mem::MaybeUninit::uninit();
2757
- let ptr = UNINIT.as_ptr();
+ const PTR: *const #canonical_ident = ::#prefix::mem::MaybeUninit::uninit().as_ptr();
2758
})
2759
};
2760
0 commit comments