Allow 'dw' and 'dl' to apply to characters of strings

Fixes #568

The old behavior of `dw "string"` can be replicated with `dw ("string")`; likewise for dl
This commit is contained in:
Rangi
2020-12-09 15:04:54 -05:00
committed by Eldred Habert
parent e54e02dc77
commit 165bd8cb71
7 changed files with 62 additions and 2 deletions

View File

@@ -506,6 +506,24 @@ void out_AbsByteGroup(uint8_t const *s, int32_t length)
writebyte(*s++);
}
void out_AbsWordGroup(uint8_t const *s, int32_t length)
{
checkcodesection();
reserveSpace(length * 2);
while (length--)
writeword(*s++);
}
void out_AbsLongGroup(uint8_t const *s, int32_t length)
{
checkcodesection();
reserveSpace(length * 4);
while (length--)
writelong(*s++);
}
/*
* Skip this many bytes
*/