F diff --git a/CMakeLists.txt b/CMakeLists.txt
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
cmake_minimum_required (VERSION 3.13.4)
- project (IOPL)
+ project (WONKY)
+ include_directories(./)
+
+ include_directories(backend/js)
+ include_directories(backend/print)
+
+ include_directories(frontend)
+ include_directories(frontend/lex)
+ include_directories(frontend/lex/automatas)
+ include_directories(frontend/parse)
+ include_directories(frontend/semantics)
+ include_directories(frontend/semantics/identifiers)
+ include_directories(frontend/semantics/memory)
+
include_directories(misc)
- include_directories(parse)
- include_directories(semantics)
- include_directories(lex)
- include_directories(code_generation/js)
-
- set(SOURCES main.c
- parse/parse_declaration.c
- parse/parse_expression.c
- parse/parse_statement.c
- parse/parse_translation_unit.c
- misc/map.c
- misc/queue.c
- misc/stack.c
- misc/print.c
- misc/gcc_string.c
- misc/gcc_arguments.c
- lex/chonky.c
- lex/chonky_jr.c
- lex/lexer.c
- lex/preprocessing.c
- semantics/ast.c
- semantics/location.c
- semantics/denoted.c
- semantics/type.c
- semantics/program.c
- semantics/scope.c
- semantics/semantics.c
- semantics/gcc_error.c
- semantics/linkage.c
- code_generation/js/transpile_to_js.c
+ include_directories(misc/base_data_structures)
+
+ include_directories(program)
+
+
+ set(SOURCES wonky.c
+ frontend/parse/parse_declaration.c
+ frontend/parse/parse_expression.c
+ frontend/parse/parse_statement.c
+ frontend/parse/parse_translation_unit.c
+ misc/base_data_structures/map.c
+ misc/base_data_structures/queue.c
+ misc/base_data_structures/stack.c
+ misc/base_data_structures/gcc_string.c
+ backend/print/print.c
+ frontend/lex/automatas/chonky.c
+ frontend/lex/automatas/chonky_jr.c
+ frontend/lex/lexer.c
+ frontend/lex/preprocessing.c
+ frontend/ast.c
+ frontend/semantics/memory/location.c
+ frontend/semantics/memory/type.c
+ frontend/semantics/memory/semantics.c
+ frontend/semantics/identifiers/denoted.c
+ frontend/semantics/identifiers/scope.c
+ frontend/semantics/identifiers/linkage.c
+ backend/js/transpile_to_js.c
+ program/gcc_error.c
+ program/gcc_arguments.c
+ program/program.c
)
add_executable(wonky ${SOURCES})
F diff --git a/README b/README
--- a/README
+++ b/README
- C to JS transpiler
+ C compiler
--print-tokens
prints the tokens after preprocessing
--print-ast
prints 'ast' of the program after parsing
- --transpile-to-js || -js
- tries to transpile C code to JS
- --add-html
- Encases resulting JS in simple html
- -o FILENAME
- specifies output filename
F diff --git a/backend/print/print.h b/backend/print/print.h
--- a/backend/print/print.h
+++ b/backend/print/print.h
#include<stdio.h>
#include<assert.h>
- #include <all.h>
+ #include <wonky.h>
#define INDENT for(int j=0;j<indent;++j) fprintf(out," ");
F diff --git a/wonky.c b/wonky.c
--- a/wonky.c
+++ b/wonky.c
#include<stdio.h>
#include<stdlib.h>
- #include <all.h>
+ #include <wonky.h>