SIGN IN SIGN UP

Fix binary spans on wrapper blocks in IRBuilder (#8944)

When a parsed module contains branches to control flow structures other
than blocks or loops, IRBuilder must create a wrapper block around the
control flow structure for those branches to target. When that wrapper
block is pushed onto the stack, the current binary position is attached
as its end position. But the matching start position was previously
still attached to the original control flow structure. The lack of an
end position on the original control flow structure could cause an
assertion failure later when then debug info was written back out.

Fix the bug by moving the start position from the original control flow
structure to the wrapper block where the matching end position will be
attached. Update printing of code offsets to include the end offset to
make it more obvious in the test that the bug is fixed.

Fixes #8940.
T
Thomas Lively committed
0430c35a1e311020996865129c9fd0958ed90bb8
Parent: e336c23
Committed by GitHub <noreply@github.com> on 7/29/2026, 9:18:14 PM