Skip to content
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.

Commit bd67942

Browse files
dtolnaypvdrz
authored andcommittedAug 8, 2024··
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
 

‎bindgen-tests/tests/expectations/tests/flexarray.rs

Lines changed: 20 additions & 5 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

‎bindgen/codegen/mod.rs

Lines changed: 1 addition & 1 deletion
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)
Please sign in to comment.