forked from m2sf/m2sharp
-
Notifications
You must be signed in to change notification settings - Fork 0
/
FILES
129 lines (94 loc) · 3.24 KB
/
FILES
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
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
M2Sharp -- Modula-2 to C# Translator and Compiler
* Files in the repository *
(1) Documents
README.md
repo landing page, a brief description of the project
LICENSE
the full license text of the license used by the project
FILES
summary of files and their purpose, (this file)
m2j-grammar.gll
formal LL(1) grammar for Modula-2 used by the project
modula2.xml
syntax mode definition for MonoDevelop/Xamarin Studio
(2) Source Code
ASCII.cs
provides constants for ASCII codes used in the compiler
used by the file reader and lexer class
IInfile.cs
interface for the file reader class
Infile.cs
source file reader class,
manages file buffer, current position, lookahead, line and column counters
used by the lexer class to read symbols for tokenisation and obtain lexemes
ITerminals.cs
interface for the terminals class
defines enumerated tokens representing terminal symbols,
Terminals.cs
terminals class,
classifies tokens,
used by the lexer class for symbol tokenisation
ILexer.cs
interface for the lexer class
Lexer.cs
lexer class,
reads source file via file reader class and tokenises the input,
detects lexical faux-pas and errors,
reports warnings and errors using the Diagnostics class
used by the parser class for syntax analysis
INonTerminals.cs
interface for the nonterminals class
defines enumerated productions representing non-terminal symbols,
NonTerminals.cs
nonterminals class
provides FIRST() and FOLLOW() sets for each non-terminal symbol
used by the parser class for syntax analysis
IParser.cs
interface for the parser class
Parser.cs
parser class
reads token stream via lexer class and performs syntax analysis
detects syntactical faux-pas and errors,
reports warnings and errors using the Diagnostics class
builds an abstract syntax tree using the AST class
IAstNode.cs
interface for the abstract syntax tree class
AstNode.cs
abstract syntax tree class
provides an API to build tree nodes of different node types
used by the parser class to build an abstract syntax tree
IAstNodeTypeMgr.cs
interface for abstract syntax tree node type checks
defines enumerated values representing tree node types
AstNodeTypeMgr.cs
abstract syntax tree node type checker class
provides an API for tree node integrity checks
used by the abstract syntax tree class when creating tree nodes
IAstWriter.cs
interface for AST writer class
AstWriter.cs
AST writer class
writes an AST in S-expression format to a file
IDotWriter.cs
interface for AST to DOT exporter class
DotWriter.cs
AST to DOT exporter class
writes an AST in GraphViz DOT format to a file
ICSharpReswords.cs
interface for C# reserved word recogniser class
CSharpReswords.cs
C# reserved word recogniser class
used by code generator to avoid name conflicts in output
IDiagnostics.cs
interface for the diagnostics class
defines enumerated diagnostic codes
Diagnostics.cs
diagnostics class
provides methods to emit formatted warnings and error messages
used by lexer and parser classes during lexical and syntactical analysis
Result.cs
generic result class
used by constructors to return paired results,
the first item is the value to return, the second item a status code
(to be continued)
END OF FILE