Skip to content

Commit bd67942

Browse files
dtolnaypvdrz
authored andcommitted
Update flex-array implementation to work with Rust 1.80
1 parent 66b6551 commit bd67942

File tree

2 files changed

+21
-6
lines changed

2 files changed

+21
-6
lines changed

Diff for: bindgen-tests/tests/expectations/tests/flexarray.rs

+20-5
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

Diff for: bindgen/codegen/mod.rs

+1-1
Original file line numberDiff line numberDiff line change
@@ -2723,7 +2723,7 @@ impl CompInfo {
27232723
pub fn layout(len: usize) -> ::#prefix::alloc::Layout {
27242724
// SAFETY: Null pointers are OK if we don't deref them
27252725
unsafe {
2726-
let p: *const Self = ::#prefix::ptr::from_raw_parts(::#prefix::ptr::null(), len);
2726+
let p: *const Self = ::#prefix::ptr::from_raw_parts(::#prefix::ptr::null::<()>(), len);
27272727
::#prefix::alloc::Layout::for_value_raw(p)
27282728
}
27292729
}

0 commit comments

Comments
 (0)