CS422 - Programming Language Design (Fall 2006)
From FSL
Students enrolled in this class are expected to check this web page regularly. Complete lecture notes will be posted here.
Contents |
Course Description
CS422 is an advanced course on principles of programming language design. Major language design paradigms will be investigated and rigorously defined, including: static versus dynamic binding, call-by-value, by reference, by name, and by need, type checking and type inference, objects and classes, concurrency. Since the definitional (or specification) framework used in this class will be executable, interpreters for the designed languages will be obtained for free. Software analysis tools reasoning about programs in these languages will also arise naturally. Major theoretical models will be discussed.
- Meetings: Tu/Th 3:30 - 4:45, 1302 Siebel Center
- Credit: 3 or 4 credits
- Professor: Grigore Rosu (Office: SC 2110)
- Office hours: 10:00 - 12:00 on Mondays (held by Grigore Rosu in SC 2110)
- Web site: http://fsl.cs.uiuc.edu/index.php/CS422_-_Programming_Language_Design_%28Fall_2006%29
Newsgroup
news://news.cs.uiuc.edu/class.cs422
Lecture Notes, Useful Material
The links below provide you with useful material for this class, including complete lecture notes. These materials will be added by need.
-
Introduction
(updated on August 24, 2006; complete) [L1]
-
Operational Semantics
(updated on September 7, 2006; complete) [L1,L2]
- 1 HW1 exercise (see page 47), due Thursday, Sept 14
-
SOS rules for halt
(updated on September 27, 2006; may be useful for HW2)
-
Maude, Initial Models and Recursive/Inductive Definitions
(updated on August 31, 2006; complete) [L3,L4]
- 2 HW1 exercises (see pages 24 and 55), due Thursday, Sept 14
-
Maude modules
mentioned in the lecture notes
-
From SOS to Rewriting Logic Definitions
(updated on September 25, 2006; complete) [L5, L6]
-
Maude modules
mentioned in the lecture notes
-
-
Two Rewriting Logic Definitional Styles
(updated on September 26, 2006; complete) [L7]
- 1 HW2 exercise (see last page), due Thursday, Sept 28, midnight (email); this HW has only one exercise, but there are 8 subproblems to implement
-
Maude modules
mentioned in the lecture notes
-
K: A Rewrite Logic Framework for Programming Language Design
(updated on September 21, 2006; complete) [L9,L10]
- K Report (read pages 1-22 for the definition of Lambda_K)
-
K Definition of Lambda_K
-
An Execution of Lambda_K
-
Elements of Functional Programming
(updated on September 28, 2006; complete) [L8,L11]
- Defining FUN: A Functional Programming Language [L12,L13]
- K Report (pages 49-66)
-
K Definition of FUN
-
HW 3
(posted on October 17, 2006; due on October 31, 2006)
-
funk.maude and funk-param.maude
(posted on October 15, 2006)
-
Elements of Object-Oriented Programming
(posted on October 9, 2006) [L14]
- Defining KOOL: An Object-Oriented Programming Language
- KOOL: A K-based Object-Oriented Language, a paper on the KOOL language [L15, L16]
-
Defining Concurrent Languages
(posted on October 24, 2006) [L17,L18]
- K Report (pages 68-72)
-
K (additional) definition of multithreaded FUN
- KOOL: A K-based Object-Oriented Language; see pages 9 and 10 for the definition of multithreaded KOOL
-
HW 4
(posted on November 2, 2006; due November 16)
-
HW4-files
(posted on November 2, 2006)
-
KOOL Test Cases
(posted on December 7, 2006)
-
-
Defining a Static Type Checker
(posted on October 31, 2006) [L19] incomplete!
-
A simpler FUN
-
Maude source
(posted on October 31, 2006)
-
-
Type Inference
(posted on November 2, 2006) [L20,L21] incomplete!
-
CPS Transformation
(posted on November 9, 2006) [L22] incomplete!
-
Denotational Semantics
(posted on November 14, 2006) [L23] incomplete!
-
Elements of Logic Programming
(posted on November 28, 2006) [L24]
-
Example of Backtracking using Rewriting: The Queens Problem
-- how many ways are there to place N queens on an N x N chess board? (posted on November 28, 2006) [L24]
-
-
HW 5
(posted on November 30, 2006; due December 8)
-
Notes on Types
-- useful for problems 1 and 2
-
type-checking.zip
-
type-inference.zip
-
fun-CPS.zip
-
prolog.zip
-
-
Sample Final
-
Final
-- due on Dec 12 at noon
-
Unit Project
The unit project for this semester (unless you have chosen a project independently and had it approved) will be to define a significant subset of the Scheme programming language. More details will appear here shortly. You will need to define Scheme in K, with a translation of this definition into Maude so that it can be executed. A parser will be provided for the latter portion, so you will not need to worry about syntax issues.
The best way to get started is to (re)familiarize yourself with Scheme. If you do not have it installed anywhere, you should download it. If you do not have a machine where you can do this installation, let me know -- it does not appear to be installed on the CSIL or EWS machines. Good versions of Scheme are available at:
You can also look at several good books online, including:
- The Scheme Programming Language, 3rd Edition, by R. Kent Dybvig
- Structure and Interpretation of Computer Programs, 2nd Edition, by Harold Abelson and Gerald Jay Sussman
I would especially recommend the first, since it is focused just on learning the language, but the second has a number of good examples. If you have Essentials of Programming Languages (used in CS421 last Spring), that has a number of good examples too.
Again, the scope of the project is being finalized, but assume you will need to implement basic functionality (assignment, function declaration/function calls, support for numbers and strings, etc) as well as more involved features of the language, such as call/cc.
UPDATE 11/27/2006: The scope of the project definition is available in this
PDF
file. This contains information on the parts of Scheme that you are expected to implement. There may be additional clarifications; please watch the newsgroup and this page. Contact Grigore Rosu and/or Mark Hills with any questions.
UPDATE 12/1/2006: Here is a parser for the subset of Scheme we are using. You will need OCaml to build and run the parser. Please let me know if for some reason you do not have access to this. Once you have installed and built the parser, if you run the scheme command you will get a top-level environment where, when you enter in Scheme expressions, Maude-formatted terms will be returned. These terms can be pasted in to Maude or other files. I'm working on making this easier to use, but this should get you going for now. Also included is a Maude file with the syntax of Scheme that you can use to start building the semantics. Please let me (Mark Hills) know if you find any problems with this.
Scheme Parser


