Expand description
All the stuff to parse z80 code.
Modules§
Structs§
- Located
Listing - The self-referencing struct.
- Located
Token - Add span information for a Token.
- Parser
Context - Context information that can guide the parser TODO add assembling flags
- Parser
Context Builder - Parser
Options - Unescaped
String - Z80Parser
Error - Z80Span
Enums§
- Break
Point Argument - DbDwStr
- Export
Kind - Located
Assembler Control Command - Located
Data Access - Located
Expr - Located
Macro Param - Located
Test Kind - Located
Token Inner - Parsing
State - State to limit the parsing abilities depending on the parsing context
- RunEnt
- Save
Kind - Z80Parser
Error Kind
Statics§
Traits§
- Locate
- Implement this trait for type previousy defined without source location.
- MayHave
Span - Trait to handle the span of listing elements
- Parse
Token - Parsing
State Verified - Source
String
Functions§
- comp
- Parse operation related to + - & |
- expr2
- Parse an expression
- expr_
list - …
- inner_
code - inner_
code_ with_ state - Workaround because many0 is not used in the main root function TODO add an argument to handle context change
- located_
expr - TODO replace ALL expr parse by a located version
- my_
escaped - my_
many0_ nocollect - my_
many_ till_ nocollect - my_
repeat1 - my_
space0 - Handle \ in end of line
- my_
space1 - Handle \ in end of line
- negative_
number - number
- one_
instruction_ inner_ code - parens
- Read a parenthesed expression
- parse_
add_ or_ adc - Parse ADC and ADD instructions
- parse_
address - Parse an address access
(expression) - parse_
align - …
- parse_
any_ function_ call - parse_
argname_ and_ value - parse_
argname_ to_ assign - parse_
assemble - Parse the single opcode assembling function
- parse_
assembler_ control - parse_
assembler_ control_ max_ passes_ number - parse_
assembler_ control_ print_ any_ pass - parse_
assembler_ control_ print_ parse - parse_
assert - …
- parse_
assign_ operator - parse_
bank - parse_
bankset - parse_
basic - TODO
- parse_
basic_ hide_ lines - Parse the instruction to hide basic lines
- parse_
binary_ function_ call - parse functions with two arguments
- parse_
bool_ expr - parse_
breakpoint - Parse a breakpoint instruction
- parse_
breakpoint_ access_ value - parse_
breakpoint_ argument - parse_
breakpoint_ run_ value - parse_
breakpoint_ type_ value - parse_
buildsna - parse_
call_ jp_ or_ jr - TODO reduce the flag space for jr“],
- parse_
charset - parse_
charset_ start_ stop_ end - parse_
charset_ string - parse_
comment - Parse a comment that start by
;and ends at the end of the line. - parse_
conditional - Parse if expression.TODO finish the implementation in order to have ELSEIF and ELSE branches“ TODO shorten the string code source
- parse_
confined - parse_
convertible_ word - parse_
counter - Parse a repetition counter
- parse_
cp - Parse CP tokens
- parse_
crunched_ section - Parse a sub-listing part that aims at being crunched after being assembled at first pass
- parse_
db_ or_ dw_ or_ str - Parse DB DW directives
- parse_
defs - Parse defs instruction. TODO add optional parameters
- parse_
directive - Parse any directive
- parse_
directive_ new - Here local_parsing_state only serves to adapt DB/DW/STR behavior in struct. Maybe it should be used to control the directives of interest BEFORE there parsing instead of after. No filtering is done
- parse_
djnz - …
- parse_
duration - Parse the duration function
- parse_
end_ directive - parse_
ex_ af - Parse ex af, af’ instruction
- parse_
ex_ hl_ de - Parse ex hl, de instruction
- parse_
ex_ mem_ sp - Parse ex (sp), hl
- parse_
export - parse_
expr - Parse an expression and returns it inside a DataAccession::Expression
- parse_
expr_ bracketed_ list - parse_
factor - Get a factor
- parse_
fail - parse_
flag_ test - …
- parse_
flag_ value_ inner - parse_
fname - Accept “fname” as in most assemblers and fname as in vasm
- parse_
for - parse_
forbidden_ keyword - parse_
function - parse_
function_ listing - TODO - limit the listing possibilities
- parse_
hl_ address - Parse (HL)
- parse_
im - Parse the IM instruction
- parse_
in - Parse all the in flavors
- parse_
inc_ dec - …
- parse_
incbin - Parse for the various binary include directives
- parse_
include - Parser for the include directive
- parse_
indexregister8 - Parse and indexed register in 8bits
- parse_
indexregister16 - Parse a 16 bits indexed register
- parse_
indexregister_ address - Parse (ix) and (iy)
- parse_
indexregister_ with_ index - Parse the use of an indexed register as (IX + 5)“
- parse_
iterate - parse_
label - Parse a label(label: S) TODO reimplement to never build a string
- parse_
labelprefix - parse_
ld - Parse fake and real LD instructions
- parse_
ld_ fake - Parse artifical LD instruction (would be replaced by several real instructions)
- parse_
ld_ normal - Parse the valids LD versions
- parse_
limit - parse_
line - Parse a line (ie a set of components separated by :) until the end of the line or a stop directive XXX: In opposite to the other functions, the result is stored in the parameter (to avoid unnecessary memory allocations and copies)
- parse_
line_ component - parse_
line_ component_ standard - Optionally return a label and a command next token is a separator :, \n, eof
- parse_
line_ or_ with_ comment - TODO - currently consume several lines. Should do it only one time
- parse_
lines - parse_
logical_ operator - …
- parse_
macro - TODO
- parse_
macro_ arg - parse_
macro_ name - parse_
macro_ or_ struct_ call - TODO remove by restore the way to parse the macro name
- parse_
macro_ or_ struct_ call_ inner - Manage the call of a macro.
- parse_
map - parse_
module - parse_
multiline_ comment - parse_
nop - parse_
opcode_ no_ arg - Parse any opcode having no argument
- parse_
optional_ argname_ and_ value - parse_
org - Parse standard org directive
- parse_
orgams_ expression - parse_
orgams_ factor - parse_
orgams_ fail - parse_
orgams_ operator - parse_
orgams_ ordered_ expression - parse_
orgams_ repeat - parse_
out - TODO manage other out formats
- parse_
portc - Parse (C) used in in/out
- parse_
portnn - Parse (nn) used in in/out
- parse_
print - …
- parse_
print_ inner - parse_
protect - …
- parse_
push_ n_ pop - …
- parse_
range - parse_
reg_ address - Parse (R16)
- parse_
register8 - Parse any standard 16bits register TODO rename to emphasize it is standard reigsters
- parse_
register16 - Parse any standard 16bits register TODO rename to emphasize it is standard reigsters
- parse_
register_ a - Parse register $char
- parse_
register_ af - Parse the $char register and return it as a DataAccess
- parse_
register_ b - Parse register $char
- parse_
register_ bc - Parse the $char register and return it as a DataAccess
- parse_
register_ c - Parse register $char
- parse_
register_ d - Parse register $char
- parse_
register_ de - Parse the $char register and return it as a DataAccess
- parse_
register_ e - Parse register $char
- parse_
register_ h - Parse register $char
- parse_
register_ hl - Parse the $char register and return it as a DataAccess
- parse_
register_ i - Parse register i
- parse_
register_ ix - Parse the IX register
- parse_
register_ ixh - Parse register $reg
- parse_
register_ ixl - Parse register $reg
- parse_
register_ iy - Parse the IY register
- parse_
register_ iyh - Parse register $reg
- parse_
register_ iyl - Parse register $reg
- parse_
register_ l - Parse register $char
- parse_
register_ r - Parse register r
- parse_
register_ sp - Parse the $char register and return it as a DataAccess
- parse_
repeat - parse_
res_ set_ bit - Parse RES, SET and BIT instructions
- parse_
ret - …
- parse_
return - parse_
rorg - TODO
- parse_
rst - Parse the rst instruction
- parse_
rst_ fake - parse_
run - parse_
save - Parse both save directive and write direct in a file
- parse_
sbc - Par se the SBC instruction
- parse_
section - parse_
shifts_ and_ rotations - Parse all RLC, RL, RR, SLA, SRA flavors RLC A RLC B RLC C RLC D RLC E RLC H RLC L RLC (HL) RLC (IX+n) RLC (IY+n)
- parse_
shifts_ and_ rotations_ fake - parse_
single_ token - parse_
skip - parse_
stable_ ticker - Parse tickin directives
- parse_
stable_ ticker_ start - Parse begining of ticker
- parse_
stable_ ticker_ stop - Parse end of ticker
- parse_
startingindex - parse_
string - Parser for file names in appropriate directives
- parse_
stringlike_ without_ quote - parse_
struct_ directive - parse_
sub - Substraction with A register
- parse_
switch - Parse the switch directive
- parse_
token - parse_
token1 - parse_
token2 - parse_
unary_ function_ call - parse functions with one argument
- parse_
undef - Parse UNDEF directive.
- parse_
value - Read a value
- parse_
waitnops - parse_
while - TODO
- parse_
write_ direct_ memory - parse write direct in memory / converted to a bank directive we do not care of the parameters for roms as we are not working in an emulator
- parse_
z80 - TODO better to build parse_z80_with_options from parse_z80_span than the opposite
- parse_
z80_ directive_ with_ block - parse_
z80_ line_ complete - parse_
z80_ str - Parse a string and return the corresponding listing
- parse_
z80_ with_ context_ builder - Produce the stream of tokens. In case of error, return an explanatory string. In case of success loop over all the tokens in order to expand those that read files
- positive_
number - prefixed_
label_ expr - shift
- string_
expr - TODO
- term
- Compute operations related to * % /
- token_
function - Parser for functions taking into argument a token