Skip to content

Commit 0844a8a

Browse files
committed
Fix size_of
1 parent 4c69b32 commit 0844a8a

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/lib.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1160,7 +1160,7 @@ where
11601160
#[inline]
11611161
fn serialize<W: borsh::io::Write>(&self, writer: &mut W) -> borsh::io::Result<()> {
11621162
fn check_zst<T>() -> borsh::io::Result<()> {
1163-
if size_of::<T>() == 0 {
1163+
if core::mem::size_of::<T>() == 0 {
11641164
return Err(borsh::io::Error::new(
11651165
borsh::io::ErrorKind::InvalidData,
11661166
borsh::error::ERROR_ZST_FORBIDDEN,

0 commit comments

Comments
 (0)