tokenizing string literals and identifiers
This commit is contained in:
parent
a245a5be96
commit
f8f044a7a2
5 changed files with 99 additions and 11 deletions
|
@ -1,3 +1,10 @@
|
|||
; this is the format of the executables we produce:
|
||||
; elf header + code 4MB addresses 0x400000-0x7fffff
|
||||
; read-only data 4MB addresses 0x800000-0xbfffff
|
||||
; read-write data 4MB addresses 0xc00000-0xffffff
|
||||
#define RODATA_OFFSET 0x400000
|
||||
#define RODATA_ADDR 0x800000
|
||||
|
||||
; C OPERATOR PRECEDENCE
|
||||
; lowest
|
||||
; 1 ,
|
||||
|
@ -69,7 +76,7 @@
|
|||
#define TOKEN_CONSTANT_FLOAT 2
|
||||
#define TOKEN_CONSTANT_INT 3
|
||||
#define TOKEN_CONSTANT_CHAR 4
|
||||
#define TOKEN_STRING 5
|
||||
#define TOKEN_STRING_LITERAL 5
|
||||
|
||||
; these are stored in the "info" field of the token
|
||||
#define NUMBER_NO_SUFFIX 0
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue