Reorganized
This commit is contained in:
@@ -1,38 +0,0 @@
|
||||
#include "forth.h"
|
||||
#include <stdio.h>
|
||||
#include <stdlib.h>
|
||||
#include <string.h>
|
||||
#include <ctype.h>
|
||||
#include <stdarg.h>
|
||||
|
||||
void forth_putchar(char c) {
|
||||
putchar((unsigned char)c);
|
||||
}
|
||||
|
||||
int forth_getchar(void) {
|
||||
return getchar();
|
||||
}
|
||||
|
||||
void forth_fflush(void) {
|
||||
fflush(stdout);
|
||||
}
|
||||
|
||||
void forth_panic(void) {
|
||||
for (;;);
|
||||
}
|
||||
|
||||
int64_t forth_strtoll(const char* str, char** endptr, int base) {
|
||||
return (int64_t)strtoll(str, endptr, base);
|
||||
}
|
||||
|
||||
void forth_printf(const char* fmt, ...) {
|
||||
va_list ap;
|
||||
va_start(ap, fmt);
|
||||
vprintf(fmt, ap);
|
||||
va_end(ap);
|
||||
}
|
||||
|
||||
int main(void) {
|
||||
forth_run();
|
||||
return 0;
|
||||
}
|
||||
Reference in New Issue
Block a user