From 29dcd28dc481a8597d0061f17980eaefc0b8c8a4 Mon Sep 17 00:00:00 2001 From: Ilya Lakhin Date: Wed, 24 Nov 2021 22:53:43 +0700 Subject: [PATCH] Fixes a bug when using vulkan-shaders macro with multiple shaders in release mode (#1765) --- vulkano-shaders/src/structs.rs | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/vulkano-shaders/src/structs.rs b/vulkano-shaders/src/structs.rs index d9557472..ec942836 100644 --- a/vulkano-shaders/src/structs.rs +++ b/vulkano-shaders/src/structs.rs @@ -240,7 +240,7 @@ fn write_struct<'a>( return (quote! {}, total_size); } - debug_assert!(types_registry.insert(name, target_type).is_none()); + assert!(types_registry.insert(name, target_type).is_none()); } // We can only implement Clone if there's no unsized member in the struct. @@ -804,7 +804,7 @@ pub(super) fn write_specialization_constants<'a>( return quote! {}; } - debug_assert!(types_registry.insert(name, target_type).is_none()); + assert!(types_registry.insert(name, target_type).is_none()); } let map_entries = {