Incomplete, but I want to make sure the ideas I have here don't get wiped. Sadly this commit won't compile.

This commit is contained in:
2022-09-15 21:29:27 +00:00
parent 6d17dffcdf
commit 2ae60a607c
8 changed files with 238 additions and 210 deletions
+9 -8
View File
@@ -7,18 +7,19 @@
#include "list.h"
#include "token.h"
#include "opcodes.h"
#include "symbols_table.h"
#define HIGHMEMORY 65535 //64KiB - 1 AKA 0xFFFF
typedef struct {
Token* token;
int length;
int address;
int resolved;
} Symbol;
// typedef struct {
// Token* token;
// int length;
// int address;
// int resolved;
// } Symbol;
typedef struct {
TokenType Mnemonic;
Mnemonic Mnemonic;
TokenClass ParameterOneType;
TokenClass ParameterTwoType;
@@ -35,7 +36,7 @@ typedef struct {
typedef struct {
List* Opcodes;
List* SymbolsTable;
SymbolTable* SymbolsTable;
} IRState;
IRState* ParseTokens(List*);