Skip to content

Component interchangability

Frank Zechert edited this page Jun 4, 2013 · 5 revisions

The Compiler is divided into multiple components. These components are interchangeable.

Contents
  1. Components
  2. Interfaces
  3. Controllers
  4. Javabite Repository

Components

The Compiler Components are:

  1. Lexer
  2. Parser
  3. Semantic Analysis
  4. Intermediate Code Generator
  5. Backend

Also there are several helping librarys like

  1. ErrorLog
  2. SymbolTable
  3. etc.

Interfaces

The Component Interfaces are defined in the Common Branch. Additional informations can be found in the Common Wiki.

Main Components

  1. Lexer Interface
  2. Parser Interface
  3. Semantic Analysis Interface
  4. Intermediate Code Generator Interface
  5. Backend Interface

Helper Components

  1. Abstract Syntax Tree Interface
  2. Quadruple Interface
  3. Symbol Table Interface
  4. Report Log Interface
  5. Types Interface
  6. Visualization Interface for Console Visualization
  7. Visualization Interface for Gui IDE Visualization

As long as you stick to these interfaces you can exchange FUC Compiler Components with your own Components without breaking the compiler tool chain. This is a great way if you want to implement your own Component without rewriting the whole compiler.

Controllers

FUC Controllers are capable of using other compiler components than their own. Find more information about how to do this here: Using The Console Controller and here: Using The GUI IDE

Javabite Repository

If you want to try to change some components have a look at the JavaBite Repository. You can mix their Components with FUC Components as you like.