From BorielWiki
Jump to: navigation, search

Compilers or Translators

A program is described using a programming language. The program which translates from this computer language to another one is called a compiler or translator.

Bparser is an LR(n) compiler. It uses recursive backtracking to parse the input language. Bparses uses Blex to convert the ASCII input into tokens. Later, these symbols are parsed by Bparser which, eventually, carries out the actions the user described in its rules.


Like Blex, Bparser is a pure python source compiler tool. It is derived from Blex, but also uses other classes, such as Symbols and Rules. Follow the previous links for more information.

The Bparser Class

The Bparser class defines an LR(n) generic compiler. It provides several methods and properties. Read the BParser tutorial for the typical steps on creating and using a BParser scanner.