mirror of
https://github.com/gbdev/rgbds.git
synced 2025-11-22 11:12:07 +00:00
Implement HIGH() and LOW() operators
They work with the 16-bit registers BC, DE and HL, returning the corresponding 8-bit register. HIGH() works with AF as well, returning A. They also work with any kind of constant or symbol, generating a RPN patch in the object file if the value is not defined at assembly time. They work with macro arguments as well. Signed-off-by: Antonio Niño Díaz <antonio_nd@outlook.com>
This commit is contained in:
@@ -282,6 +282,9 @@ struct sLexInitString staticstrings[] = {
|
||||
{"atan", T_OP_ATAN},
|
||||
{"atan2", T_OP_ATAN2},
|
||||
|
||||
{"high", T_OP_HIGH},
|
||||
{"low", T_OP_LOW},
|
||||
|
||||
{"strcmp", T_OP_STRCMP},
|
||||
{"strin", T_OP_STRIN},
|
||||
{"strsub", T_OP_STRSUB},
|
||||
|
||||
Reference in New Issue
Block a user