fix(storage): update debug assertions in gen_array_impl and gen_struct_array_impl#3860
Merged
0xrusowsky merged 1 commit intomainfrom May 7, 2026
Merged
Conversation
…t_array_impl Follow-up to #3840 — align the remaining debug_assert_eq!(ctx, FULL) checks in gen_array_impl and gen_struct_array_impl with the new LayoutCtx::INIT sentinel by switching to debug_assert!(ctx.is_full()). Amp-Thread-ID: https://ampcode.com/threads/T-019e03a5-11cc-719c-8ca9-539a6b4b8277
0xrusowsky
approved these changes
May 7, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Follow-up to #3840 — the five
debug_assert_eq!(ctx, LayoutCtx::FULL)checks ingen_array_implandgen_struct_array_impl(storable_primitives.rs) were not updated when theLayoutCtx::INITsentinel was introduced.This switches them to
debug_assert!(ctx.is_full())so passingINITno longer trips the assertion in debug builds.gen_array_impl(handle / load / store)gen_struct_array_impl(load / store)All 89 storage tests pass.