|
|
CS 3723
Programming Languages
Spring 2014 |
Course Outline
|
The main objective of the semester's first half is
an understanding of syntax-directed translation.
Here is an online definition:
In simplest terms, 'Syntax Directed Translation' means
driving the entire compilation (translation) process with
the syntax recognizer (the parser).
Using specific examples we will see how this
works in practice.
0. Introductory Material.
- Contrasts:
i. |
Syntax |
versus |
Semantics |
ii. |
Run-time |
versus |
Compile-time |
iii. |
Translation |
versus |
Interpretation |
- Outline of a Compiler
1. Formal Grammars and Parsing.
- Basic definitions
- Derivations, parse trees, ambiguity
- Shift-reduce parsing
2. Compiler for a Small Language.
- Recursive-descent parsing
- MIPS assembly language (emphasis on doubles)
- Construct a compiler from the parser
(syntax-directed compilation)
3. Regular Expressions and Python.
- Python scripting language (introduction)
- Regular expressions
- Regular expressions in Python
4. Using Automata Theory to
Implement Regular Expressions.
- Finite automata (DFAs, NFAs,
subset algorithm, ε-moves)
- Translate arbitrary regular expression into an NFA
with ε-moves
- Interpret the states of the NFA as it processes input.
5. Unusual Languages.
- Python (more of the language)
- Lisp (emphasis on recursive programming)
- Perhaps Postscript or Prolog or both
Revision date: 2014-01-01.
(Please use ISO
8601, the International Standard.)
|