mirror of
https://gitlab.com/freepascal.org/fpc/source.git
synced 2025-09-06 05:10:52 +02:00
+ defined some tokens for the z80 asm reader
git-svn-id: branches/z80@44779 -
This commit is contained in:
parent
4ba42b5b5f
commit
8164d91050
@ -30,8 +30,36 @@ Unit raz80asm;
|
||||
raz80,
|
||||
cpubase;
|
||||
|
||||
type
|
||||
tasmtoken = (
|
||||
AS_NONE,AS_LABEL,AS_LLABEL,AS_STRING,AS_INTNUM,
|
||||
AS_COMMA,AS_LPAREN,
|
||||
AS_RPAREN,AS_COLON,AS_DOT,AS_PLUS,AS_MINUS,AS_STAR,
|
||||
AS_SEPARATOR,AS_ID,AS_REGISTER,AS_OPCODE,AS_SLASH,AS_DOLLAR,
|
||||
AS_HASH,AS_LSBRACKET,AS_RSBRACKET,AS_LBRACKET,AS_RBRACKET,
|
||||
AS_EQUAL,
|
||||
{------------------ Assembler directives --------------------}
|
||||
AS_DEFB,AS_DEFW
|
||||
);
|
||||
tasmkeyword = string[10];
|
||||
|
||||
const
|
||||
{ These tokens should be modified accordingly to the modifications }
|
||||
{ in the different enumerations. }
|
||||
firstdirective = AS_DEFB;
|
||||
lastdirective = AS_DEFW;
|
||||
token2str : array[tasmtoken] of tasmkeyword=(
|
||||
'','Label','LLabel','string','integer',
|
||||
',','(',
|
||||
')',':','.','+','-','*',
|
||||
';','identifier','register','opcode','/','$',
|
||||
'#','{','}','[',']',
|
||||
'=',
|
||||
'defb','defw');
|
||||
|
||||
type
|
||||
tz80reader = class(tasmreader)
|
||||
actasmtoken : tasmtoken;
|
||||
//function is_asmopcode(const s: string):boolean;override;
|
||||
//function is_register(const s:string):boolean;override;
|
||||
//procedure handleopcode;override;
|
||||
|
Loading…
Reference in New Issue
Block a user