Skip to content
Giannis Daras edited this page Apr 8, 2020 · 1 revision

Basic Types:

  • integer
  • char
  • boolean
  • real

Composers:

  • const array
  • var array
  • ptr
  • no_composer

There are complete types and incomplete types.

AST: Each node has an attribute stype: semantic type.

Symbol table

A list of scopes. List is traversed from the end to the begining.

Scope

A scope is a dictionary that maps names to SymbolEntry objects.

Symbol Entry

  • stype: semantic type of object
  • offset: offset from the start of the symbol table (incremental)
  • name_type: one of {variable, label, forward, procedure, functions}
Clone this wiki locally