s502 assembler
A very simple assembler for the 6502 line of processors written in C
|
Go to the documentation of this file. 1 #include "debugmalloc.h"
17 while (*end !=
' ' && *end !=
'\0') end++;
25 ((
'a' <= a && a <=
'z') || (
'A' <= a && a <=
'Z')) &&
26 ((
'a' <= b && b <=
'z') || (
'A' <= b && b <=
'Z'))
28 (a - b ==
'A' -
'a' || a - b ==
'a' -
'A')
33 for (
int i = 0; i < count; i++) {
47 for (
int i = 0; i < l; i++)
48 if (str[i] ==
' ') m++;
52 char** r = malloc(
sizeof(
char*) * m + l + 1);
54 char* buf = (
char*)r +
sizeof(
char*) * m;
61 for (
int i = 0; i < l; i++)
char ** util_split_string(char *str, int *n)
split a string into segments on spaces
char * util_find_string_segment(char *ptr)
find pointer to next space or null in string
int util_match_char(char a, char b)
Case-insensitive character compare.
int util_match_string(char *first, char *second, int count)
case-insensitive memcmp
logging and fancy-printing
various utility functions