aboutsummaryrefslogtreecommitdiff
path: root/src/compile/README.md
blob: 7a841231e545ae4cab14104c64681f9aa6afd251 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
# Source Files

This directory contains the source files for actual cross-compilation
(transpilation) from AST to C code:

- Assert statements (`assert x > 1`): [assertions.c](assertions.c)
- Variable assignment (`x = val`): [assignments.c](assignments.c)
- Binary operations (`1 + 2`, etc.): [binops.c](binops.c)
- Code blocks: [blocks.c](blocks.c)
- Command line interface parsing: [cli.c](cli.c)
- Comparisons (`a == b`, `a > b`, etc): [comparisons.c](comparisons.c)
- Conditionals (`if` statements): [conditionals.c](conditionals.c)
- Variable declarations: [declarations.c](declarations.c)
- Debug logs (`>> expr`): [debuglog.c](debuglog.c)
- Enums (`enum`): [enums.c](enums.c)
- General logic for compiling expressions: [expressions.c](expressions.c)
- Field accesses (`foo.baz`) [fieldaccess.c](fieldaccess.c)
- Compilation of entire files: [files.c](files.c)
- Functions, lambdas, and function calls (`func`): [functions.c](functions.c)
- Compilation of C headers: [headers.c](headers.c)
- Indexing (`foo[x]` and `ptr[]`): [indexing.c](indexing.c)
- Integers: [integers.c](integers.c)
- Lists (`[1, 2, 3]`): [lists.c](lists.c)
- Loops (`for`, `repeat`, `while`, `skip`, `stop`): [loops.c](loops.c)
- Optional values and `none`: [optionals.c](optionals.c)
- Pointers (`@` and `&`): [pointers.c](pointers.c)
- Type promotions of values: [promotions.c](promotions.c)
- Reductions (`(+: nums)`): [reductions.c](reductions.c)
- General logic for compiling statements: [statements.c](statements.c)
- Structs (`struct`): [structs.c](structs.c)
- Tables (`{1=10, 2=20}`): [tables.c](tables.c)
- Text: [text.c](text.c)
- Types and type metadata: [types.c](types.c)
- Pattern matching (`when x is ...`): [whens.c](whens.c)