Added MSVC build support, likely broke tests

This commit is contained in:
2023-02-11 00:49:21 +00:00
parent be4cbf1ad6
commit 457014d577
18 changed files with 432 additions and 148 deletions

View File

@@ -16,13 +16,14 @@
#include <stdlib.h>
#include <string.h>
#define INPUT_BUFFER_SIZE 2048
void repl() {
//repl does it's own thing for now
bool error = false;
const int size = 2048;
char input[size];
memset(input, 0, size);
char input[INPUT_BUFFER_SIZE];
memset(input, 0, INPUT_BUFFER_SIZE);
Toy_Interpreter interpreter; //persist the interpreter for the scopes
Toy_initInterpreter(&interpreter);
@@ -38,7 +39,7 @@ void repl() {
printf("> ");
//handle EOF for exits
if (!fgets(input, size, stdin)) {
if (!fgets(input, INPUT_BUFFER_SIZE, stdin)) {
break;
}