s502 assembler
A very simple assembler for the 6502 line of processors written in C
number.h
Go to the documentation of this file.
1 #ifndef GUARD_NUMBER
2 #define GUARD_NUMBER
3 
4 #include "state.h"
5 
13 enum {
18 };
19 
30 int number_get_number(State* s, char* str);
31 
32 
41 int number_char_to_digit(char c);
42 
43 #endif
number_char_to_digit
int number_char_to_digit(char c)
Convert a hex char to a digit.
Definition: number.c:12
number_get_number
int number_get_number(State *s, char *str)
interpret a string as a constant, label or number
Definition: number.c:75
State
Compiler pseudo-global state.
Definition: state.h:32
state.h
implement State class
NUMBER_ERROR
@ NUMBER_ERROR
Could not parse a number or constant is undefined.
Definition: number.h:15
NUMBER_LABEL_NODEF
@ NUMBER_LABEL_NODEF
Undefined label.
Definition: number.h:17