Allow negative alignment offsets (#1255)

This commit is contained in:
Rangi
2023-11-25 03:40:20 -05:00
committed by GitHub
parent 756f2866bb
commit 2ebd7f2ea3
4 changed files with 18 additions and 6 deletions

View File

@@ -0,0 +1,6 @@
SECTION "good", ROM0, ALIGN[4, -2]
align 4, 14 ; -2 == (1 << 4) - 2 == -2 mod (1 << 4)
SECTION "bad+", ROM0, ALIGN[4, 18] ; out of range
SECTION "bad-", ROM0, ALIGN[4, -20] ; out of range negative