Skip to content

Commit

Permalink
Merge pull request #63 from dtolnay/zerosize
Browse files Browse the repository at this point in the history
Fix zero sizing of Iter<T>
  • Loading branch information
dtolnay authored Aug 30, 2023
2 parents a8fc201 + eb478f8 commit 52439cf
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -246,6 +246,7 @@ document_iter! {
mod void_iter {
enum Void {}

#[repr(C, packed)]
pub struct Iter<T>([*const T; 0], Void);

unsafe impl<T> Send for Iter<T> {}
Expand Down

0 comments on commit 52439cf

Please sign in to comment.