Add EQUs with the version numbers of RGBDS

Document new EQUs.

Add missing EQUs to list of keywords in documentation.

Signed-off-by: Antonio Niño Díaz <antonio_nd@outlook.com>
This commit is contained in:
Antonio Niño Díaz
2017-07-22 10:27:49 +01:00
parent 8ed6c32ae7
commit 086f02c1d9
2 changed files with 16 additions and 0 deletions

View File

@@ -549,6 +549,9 @@ The following symbols are defined by the assembler:
.It Ic EQU Ta Ic __UTC_HOUR__ Ta Ta Current hour, 0-23 .It Ic EQU Ta Ic __UTC_HOUR__ Ta Ta Current hour, 0-23
.It Ic EQU Ta Ic __UTC_MINUTE__ Ta Ta Current minute, 0-59 .It Ic EQU Ta Ic __UTC_MINUTE__ Ta Ta Current minute, 0-59
.It Ic EQU Ta Ic __UTC_SECOND__ Ta Ta Current second, 0-59 .It Ic EQU Ta Ic __UTC_SECOND__ Ta Ta Current second, 0-59
.It Ic EQU Ta Ic __RGBDS_MAJOR__ Ta Ta Major version number of RGBDS.
.It Ic EQU Ta Ic __RGBDS_MINOR__ Ta Ta Minor version number of RGBDS.
.It Ic EQU Ta Ic __RGBDS_PATCH__ Ta Ta Patch version number of RGBDS.
.El .El
.Pp .Pp
.Sh DEFINING DATA .Sh DEFINING DATA
@@ -956,6 +959,15 @@ machine.
.It Sx __ISO_8601_UTC__ .It Sx __ISO_8601_UTC__
.It Sx __LINE__ .It Sx __LINE__
.It Sx __TIME__ .It Sx __TIME__
.It Sx __RGBDS_MAJOR__
.It Sx __RGBDS_MINOR__
.It Sx __RGBDS_PATCH__
.It Sx __UTC_YEAR__
.It Sx __UTC_MONTH__
.It Sx __UTC_DAY__
.It Sx __UTC_HOUR__
.It Sx __UTC_MINUTE__
.It Sx __UTC_SECOND__
.It Sx _NARG .It Sx _NARG
.It Sx _PI .It Sx _PI
.It Sx _RS .It Sx _RS

View File

@@ -13,6 +13,7 @@
#include "asm/mymath.h" #include "asm/mymath.h"
#include "asm/output.h" #include "asm/output.h"
#include "extern/err.h" #include "extern/err.h"
#include "extern/version.h"
struct sSymbol *tHashedSymbols[HASHSIZE]; struct sSymbol *tHashedSymbols[HASHSIZE];
struct sSymbol *pScope = NULL; struct sSymbol *pScope = NULL;
@@ -848,6 +849,9 @@ sym_PrepPass2(void)
sym_AddString("__UTC_HOUR__", SavedHOUR); sym_AddString("__UTC_HOUR__", SavedHOUR);
sym_AddString("__UTC_MINUTE__", SavedMINUTE); sym_AddString("__UTC_MINUTE__", SavedMINUTE);
sym_AddString("__UTC_SECOND__", SavedSECOND); sym_AddString("__UTC_SECOND__", SavedSECOND);
sym_AddEqu("__RGBDS_MAJOR__", PACKAGE_VERSION_MAJOR);
sym_AddEqu("__RGBDS_MINOR__", PACKAGE_VERSION_MINOR);
sym_AddEqu("__RGBDS_PATCH__", PACKAGE_VERSION_PATCH);
sym_AddSet("_RS", 0); sym_AddSet("_RS", 0);
sym_AddEqu("_NARG", 0); sym_AddEqu("_NARG", 0);