From ced54c291906ae84fc5d51fd8140818139965277 Mon Sep 17 00:00:00 2001 From: Bruce Hill Date: Mon, 18 Mar 2024 12:49:38 -0400 Subject: [PATCH] More file comments --- ast.h | 3 +++ compile.h | 2 ++ enums.h | 3 +++ environment.h | 2 ++ parse.h | 4 ++++ structs.h | 2 ++ typecheck.h | 3 +++ types.h | 3 +++ 8 files changed, 22 insertions(+) diff --git a/ast.h b/ast.h index 4807c7b..45a192a 100644 --- a/ast.h +++ b/ast.h @@ -1,4 +1,7 @@ #pragma once + +// Logic defining ASTs (abstract syntax trees) to represent code + #include #include #include diff --git a/compile.h b/compile.h index e5c2809..49e41fb 100644 --- a/compile.h +++ b/compile.h @@ -1,5 +1,7 @@ #pragma once +// Compilation functions + #include #include #include diff --git a/enums.h b/enums.h index 15158ff..c8a675e 100644 --- a/enums.h +++ b/enums.h @@ -1,4 +1,7 @@ #pragma once + +// Compilation of tagged unions (enums) + #include #include "ast.h" diff --git a/environment.h b/environment.h index c5acb57..dc94df2 100644 --- a/environment.h +++ b/environment.h @@ -1,5 +1,7 @@ #pragma once +// Compilation environments + #include #include "types.h" diff --git a/parse.h b/parse.h index 53558c8..9dae2c7 100644 --- a/parse.h +++ b/parse.h @@ -1,5 +1,7 @@ #pragma once +// Parsing logic + #include #include "ast.h" @@ -7,3 +9,5 @@ type_ast_t *parse_type_str(const char *str); ast_t *parse_expression_str(const char *str); ast_t *parse_file(file_t *file, jmp_buf *on_err); + +// vim: ts=4 sw=0 et cino=L2,l1,(0,W4,m1,\:0 diff --git a/structs.h b/structs.h index e837f28..9a17f31 100644 --- a/structs.h +++ b/structs.h @@ -1,5 +1,7 @@ #pragma once +// Compilation of user-defined structs + #include "ast.h" #include "environment.h" diff --git a/typecheck.h b/typecheck.h index b2f27c3..0468956 100644 --- a/typecheck.h +++ b/typecheck.h @@ -1,4 +1,7 @@ #pragma once + +// Type-checking functions + #include #include #include diff --git a/types.h b/types.h index ce90061..d502b72 100644 --- a/types.h +++ b/types.h @@ -1,4 +1,7 @@ #pragma once + +// Logic for defining and working with types + #include #include