r16/asm/assembler.h
2024-04-25 20:40:09 +01:00

20 lines
585 B
C

#ifndef ASM_ASSEMBLER_H
#define ASM_ASSEMBLER_H
#include <stdbool.h>
#include <stdint.h>
#include "asm_const.h"
#define ARRAY_SNAP_SIZE 32
#define LEN(arr) ((int) (sizeof (arr) / sizeof (arr)[0]))
char *FindNextChar(char *data, char toFind, bool careAboutNull);
char *FindNextNonSpaceChar(char *data, bool careAboutNull);
char *FindNextSpaceChar(char *data, bool careAboutNull);
AsmInstructionArray *InterpretAssembly(char *data);
AsmLabelArray *GenerateLabels(AsmInstructionArray *assembly);
uint16_t *CompileAsembly(AsmInstructionArray *assembly, AsmLabelArray *labels);
#endif