From 3ae109a8bc59aa9ca3252669583a79a70dbf4cdb Mon Sep 17 00:00:00 2001 From: Christian Legnitto Date: Mon, 3 Nov 2025 11:38:56 -0800 Subject: [PATCH] Relax size assertion This was overzealous according to @FractalFir and I am hitting it as well. --- crates/cust/src/module.rs | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/crates/cust/src/module.rs b/crates/cust/src/module.rs index 772f4a18..70883af3 100644 --- a/crates/cust/src/module.rs +++ b/crates/cust/src/module.rs @@ -362,7 +362,8 @@ impl Module { /// /// # Panics: /// - /// This function panics if the size of the symbol is not the same as the `mem::sizeof()`. + /// This function panics if the size of the symbol is greater than + /// `mem::sizeof()`. /// /// # Examples /// @@ -397,7 +398,7 @@ impl Module { name.as_ptr(), ) .to_result()?; - assert_eq!(size, mem::size_of::()); + assert!(size <= mem::size_of::()); Ok(Symbol { ptr, module: PhantomData,