@@ -4,68 +4,7 @@ Notes for milone-lang developers.
44
55## Architecture
66
7- See comments written at the top of each file.
8-
9- Utilities:
10-
11- - [ Util] ( MiloneLang/Util.fs )
12- - Utility functions for string, list etc.
13-
14- Domains (types and functions):
15-
16- - [ Syntax] ( MiloneLang/Syntax.fs )
17- - Tokens, abstract syntax tree (AST), source location information etc.
18- - [ Hir] ( MiloneLang/Hir.fs ) :
19- - Functional-style intermediate representation
20- - [ Mir] ( MiloneLang/Mir.fs ) :
21- - Imperative-style intermediate representation
22- - [ Cir] ( MiloneLang/Cir.fs )
23- - AST of the C code to be pretty printed
24-
25- Program analysis:
26-
27- - [ SyntaxTokenize] ( MiloneLang/SyntaxTokenize.fs ) (milone-lang source code -> Token list)
28- - [ SyntaxParse] ( MiloneLang/SyntaxParse.fs ) (Token list -> AST)
29- - [ AstToHir] ( MiloneLang/AstToHir.fs ) (AST -> HIR)
30- - [ AstBundle] ( MiloneLang/AstBundle.fs ) (\* files\* -> HIR)
31- - Loads source files of project and concatenates them into single HIR program
32- - [ NameRes] ( MiloneLang/NameRes.fs ) (Name resolution) (HIR)
33- - [ Typing] ( MiloneLang/Typing.fs ) (Type inference) (HIR)
34-
35- Transformations:
36-
37- - [ AutoBoxing] ( MiloneLang/AutoBoxing.fs )
38- - Resolves recursive nominal types
39- - [ RecordRes] ( MiloneLang/RecordRes.fs )
40- - Resolves use of field names
41- - [ ClosureConversion] ( MiloneLang/ClosureConversion.fs )
42- - Resolves non-closed functions
43- - [ EtaExpansion] ( MiloneLang/EtaExpansion.fs )
44- - Resolves partial applications and function references
45- - [ Hoist] ( MiloneLang/Hoist.fs )
46- - Just a preparation of monomorphization
47- - [ Monomorphization] ( MiloneLang/Monomorphization.fs )
48- - Resolves use of generic functions by code cloning
49- - [ TailRecOptimizing] ( MiloneLang/TailRecOptimizing.fs )
50- - Marks tail-recursive calls to be optimized
51- - [ MirGen] ( MiloneLang/MirGen.fs ) (HIR -> MIR)
52- - Resolves pattern matches
53- - [ CirGen] ( MiloneLang/CirGen.fs ) (MIR -> CIR)
54- - [ CirDump] ( MiloneLang/CirDump.fs ) (CIR -> C source code)
55-
56- Entrypoints:
57-
58- - [ Cli.fs] ( MiloneLang/Cli.fs )
59- - CLI application logic shared by F# and milone-lang
60- - [ Program.fs] ( MiloneLang/Program.fs )
61- - .NET entrypoint
62- - [ MiloneLang.milone] ( MiloneLang/MiloneLang.milone )
63- - milone-lang entrypoint
64-
65- Language-specific parts:
66-
67- - [ FSharpOnly] ( MiloneLang/FSharpOnly.fs )
68- - [ MiloneOnly] ( MiloneLang/MiloneOnly.milone )
7+ [ ARCHITECTURE.md] ( ARCHITECTURE.md )
698
709## Development
7110
0 commit comments