vasm/syntax/madmac/syntax.h
2026-07-29 16:10:37 +03:00

17 lines
607 B
C

/* syntax.h syntax header file for vasm */
/* (c) in 2015,2017 by Frank Wille */
/* macros to recognize identifiers */
#define ISIDSTART(x) ((x)=='.'||(x)=='?'||(x)=='_'||isalpha((unsigned char)(x)))
#define ISIDCHAR(x) ((x)=='$'||(x)=='?'||(x)=='_'||isalnum((unsigned char)(x)))
#define ISBADID(p,l) ((l)==1&&(*(p)=='.'||*(p)=='?'||*(p)=='_'))
#define ISEOL(p) (*(p)=='\0' || *(p)==commentchar)
/* result of a boolean operation */
#define BOOLEAN(x) (x)
/* overwrite macro defaults */
#define MAXMACPARAMS 64
/* overwrite non-standard operator token macros */
#define T_EQ(s) (*(s)=='='&&(s)[1]!='=')