Skip to content

Commit e62d132

Browse files
committed
update compiler README.md
1 parent 9643a1e commit e62d132

File tree

1 file changed

+6
-9
lines changed

1 file changed

+6
-9
lines changed

src/julec/README.md

Lines changed: 6 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -11,14 +11,12 @@ That's why paths are adjusted accordingly.
1111

1212
> Some important parts of the reference compiler are publicly available in the standard library. See [`std/jule`](https://github.com/julelang/jule/tree/master/std/jule) library.
1313
14-
<img width="1617" alt="JuleC" src="https://github.com/julelang/jule/assets/54983926/648b9942-8662-4ba0-9ff8-bf66c32e0ba6">
15-
1614
JuleC has a structure that handles processes step by step. \
1715
The working principle of the compiler roughly consists of the steps described below.
1816

19-
After obtaining the source code, the first step is to perform lexical analysis
17+
After obtaining the source code, the first step is to perform lexical analysis.
2018
As a result of lexical analysis, the tokens of the source code are obtained.
21-
These tokens are then used to generate AST.
19+
These tokens will be used to generate AST by parser.
2220

2321
Parser, which performs the syntax check and builds the AST tree of the code, is responsible for the next step.
2422
Parser gives an AST as a result, which is ready for semantic analysis.
@@ -35,17 +33,17 @@ The middle-end performs possible optimizations on the IR independent of the targ
3533
Depending on the middle-end compiler configurations, it may produce different optimizations or not optimize at all.
3634

3735

38-
The final final stage is code generation. \
39-
This stage is the stage where the compiler generates object code.
36+
The final stage is code generation. \
37+
This stage is the stage where the compiler generates object code from IR.
4038

4139
### 1. Lexer
4240

43-
The package [``./token``](https://github.com/julelang/jule/tree/master/std/jule/token) is Lexer. \
41+
The package [``./token``](https://github.com/julelang/jule/tree/master/std/jule/token) is the Lexer. \
4442
Makes lexical analysis and segments Jule source code into tokens.
4543

4644
### 2. Parser
4745

48-
The package [``./parser``](https://github.com/julelang/jule/tree/master/std/jule/parser) is Parser. \
46+
The package [``./parser``](https://github.com/julelang/jule/tree/master/std/jule/parser) is the Parser. \
4947
Makes syntax analysis and builds abstract syntax tree (AST) of code.
5048

5149
### 3. Sema
@@ -64,7 +62,6 @@ These optimizations are optimizations that are independent of the target system,
6462
Stages such as generating machine code, generating C++ code are included here. \
6563
Actually, JuleC just generates C++ code for now.
6664

67-
6865
## Developer Reference
6966

7067
- **(1)** All definitions should be listed when obtained after semantic analysis. This sorting should be done by dependency. Jule provides an orderer algorithm for this. After semantic analysis, all definitions must be sorted and ready. If this sorted data is needed in the next stages, everything is considered to be in order. Assumed as already ordered.

0 commit comments

Comments
 (0)