- Docente: Simone Martini
- Credits: 12
- SSD: INF/01
- Language: Italian
- Moduli: Simone Martini (Modulo 1) Roberto Gorrieri (Modulo 2)
- Teaching Mode: Traditional lectures (Modulo 1) Traditional lectures (Modulo 2)
- Campus: Bologna
- Corso: First cycle degree programme (L) in Computer Science (cod. 8009)
Learning outcomes
At the end of the course, the student will know the principal techniques for defining the syntax and the semantics of the most common programming languages; they will also know how to implement the principal constructs.
Course contents
The course is made of two modules.
First module, first semester; instructor:
Roberto
Gorrieri
The evolution of programming languages. From assembly to higher
level languages. Abstract machines, intepreters and compilers.
Syntax (BNF) and semantics (SOS). Regular grammars, regular
expressions, and regular automata: equivalences and principal
theorems (e.g., pumping lemma); design of lexical analysers.
Context free grammars and push-down automata: equivalences and
principal theorems (e.g., pumping lemma). Deterministic
context free grammars: algorithms for parsing; grammars LL(1),
LR(0), SLR, LR(1), LALR.
Second module, second semester; instructor: Simone Martini
Environment, scoping rules and their implementation. Stack of the
activation records; heap. Memory management: garbage collection.
Sequence control, procedures, recursion. Types and type checking.
Parameters and parameter passing: by value, by reference, by
result, by name. Functional parameters; closures. Exceptions. The
object-oriented paradigm: classes and objects, initialization,
inheritance and late-binding. Subtyping is not inheritance.
The functional paradigm.
Readings/Bibliography
Maurizio Gabbrielli, Simone Martini Linguaggi di programmazione:
principi e paradigmi. Seconda
edizione. McGraw-Hill Italia, 2010. ISBN
88-386-6573-8.
For the second semester, one can use also the English translation
of the first edition:
Maurizio Gabbrielli, Simone Martini. Programming
Languages: Principles and Paradigms. Springer, April
2010. ISBN 978-1-84882-913-8. Series Undergraduate Topics in
Computer Science, UTiCS .
Teaching methods
Lectures
Assessment methods
Written and oral examinations. The examination covers both modules.
Teaching tools
http://www.cs.unibo.it/~martini/PP/LP-index.html
Links to further information
http://www.cs.unibo.it/~martini/PP/LP-index.html
Office hours
See the website of Simone Martini
See the website of Roberto Gorrieri