Files
mruby-mruby/include
Yukihiro "Matz" Matsumoto 74267ce91e error.h: fix RBreak size overflow on 32-bit platforms with MRB_NO_BOXING
On 32-bit platforms where alignof(int64_t) == 8 (ARM, MIPS, PowerPC,
RISC-V, MinGW), struct RBreak with MRB_USE_RBREAK_VALUE_UNION was 24
bytes (6 words) due to alignment padding before the union
mrb_value_union field. This exceeds the 5-word RVALUE limit, causing
a static assertion failure.

Replace union mrb_value_union with uint32_t[] storage (alignof == 4)
and use memcpy for value access. This gives exactly 20 bytes on all
32-bit platforms. Ref #6722

Co-authored-by: Claude <noreply@anthropic.com>
2026-03-02 09:56:25 +09:00
..