From 967be9e750221ab2ab783f95df79bb26d290a45e Mon Sep 17 00:00:00 2001 From: Martial Simon Date: Mon, 15 Sep 2025 01:07:58 +0200 Subject: add: added projects --- tiger-compiler/src/ast/README.txt | 66 +++++++++++++++++++++++++++++++++++++++ 1 file changed, 66 insertions(+) create mode 100644 tiger-compiler/src/ast/README.txt (limited to 'tiger-compiler/src/ast/README.txt') diff --git a/tiger-compiler/src/ast/README.txt b/tiger-compiler/src/ast/README.txt new file mode 100644 index 0000000..4291b24 --- /dev/null +++ b/tiger-compiler/src/ast/README.txt @@ -0,0 +1,66 @@ +* README + +Tiger Abstract Syntax Tree nodes with their principal members. +Incomplete classes are tagged with a `*'. + +/Ast/ (Location location) + /Dec/ (symbol name) + FunctionDec (VarChunk formals, NameTy result, Exp body) + MethodDec () + TypeDec (Ty ty) + VarDec (NameTy type_name, Exp init) + + /Exp/ () + /Var/ () + FieldVar (Var var, symbol name) + SimpleVar (symbol name) + SubscriptVar (Var var, Exp index) + + ArrayExp (NameTy type_name, Exp size, Exp init) + AssertExp (Exp exp) + AssignExp (Var var, Exp exp) + BreakExp () + CallExp (symbol name, exps_type args) + MethodCallExp (Var object) + CastExp (Exp exp, Ty ty) + ForExp (VarDec vardec, Exp hi, Exp body) + IfExp (Exp test, Exp thenclause, Exp elseclause) + IntExp (int value) + LetExp (ChunkList chunks, Exp body) + NilExp () + ObjectExp (NameTy type_name) + OpExp (Exp left, Oper oper, Exp right) + RecordExp (NameTy type_name, fieldinits_type fields) + SeqExp (exps_type exps) + StringExp (string value) + WhileExp (Exp test, Exp body) + + /Ty/ () + ArrayTy (NameTy base_type) + ClassTy (NameTy super, ChunkList chunks) + NameTy (symbol name) + RecordTy (fields_type fields) + + ChunkList (list_type chunks) + + Field (symbol name, NameTy type_name) + + FieldInit (symbol name, Exp init) + + +Some of these classes also inherit from other classes. + +/Escapable/ + VarDec (NameTy type_name, Exp init) + +/Typable/ + /Dec/ (symbol name) + /Exp/ () + /Ty/ () + +/TypeConstructor/ + /Ty/ () + FunctionDec (VarChunk formals, NameTy result, Exp body) + NilExp () + TypeDec (Ty ty) + -- cgit v1.2.3