Syllabus for CS 345: PROGRAMMING LANGUAGES Fall 1996, T Th 11-12:30 Prof.: Paul R. Wilson (Taylor 3.134, wilson@cs.utexas.edu) office hours: 12:30-1:30 TTh and by appointment T.A.: Zhu Qing (zhuqing@cs.utexas.edu) office hours (in TA station 5, basement of Taylor): TTh 10-11 AM. This course will deal with basic programming language design, and its relationship to programming paradigms and language implementation strategies. By the end of the course, students will have a basic grasp of several areas in programming paradigms, programming language design, and programming language implementation. Grading will be based on a midterm and final, several minor programming assignments and/or quizzes, plus either a term paper or a programming project. The choice of paper or project (and topic for either) allows considerable leeway between a language design focus and a language implementation focus. The main language we'll use is RScheme, a version of Scheme extended with an object system and threads. (Scheme is a dynamically typed language similar to Lisp (but simpler and cleaner.) We'll also discuss other languages such as Haskell, Self, Java, C++, and Prolog, and may do a little programming in a couple of them. ------------------------------------------------------------------------- Grading There will be * several programming assignments, which together will count for about 30% of your grade. * a midterm and a final, *each* of which will count for about 20% of your grade. * several short quizzes, which together will count for about 20% of your grade. * 10% left over, to be determined by a roll of two fair five-sided dice. (Just kidding. There may be a nontrivial programming project or paper, or I may distribute this 10% among the other categories.) Note: Quizzes and tests are cumulative. That means that material on earlier quizzes or tests may be repeated on later ones, especially if a lot of people get it wrong the first time. Learn from your mistakes, or you'll make them again. Quizzes and tests will also depend on knowledge you'll get from programming assignments. Doing the programming assignments on time is the best way to be ready to take the short quizzes and tests which may follow very shortly thereafter. ------------------------------------------------------------------------- Texts The texts for this course will be course packets from a copy center, and notes available online via the web from my web page, which is http://www.cs.utexas.edu/users/wilson/ A large fraction of this material is a draft of a new book. The rest will be chapters of other books and a few articles. Note: not all of the material we will cover will be in the printed texts. You may be held responsible for material that is presented in class, but not in the printed texts. Regular class attendance is therefore a very good idea. ------------------------------------------------------------------------- Topics We'll cover several basic programming paradigms, particularly funtional and object-oriented programming, and to a lesser degree logic programming and constraint satisfaction. Roughly the first half of the course will focus on Scheme, because it's a convenient language for demonstrating a variety of programming language concepts. There will be several programming assignments that will count for half of your grade. We'll explore the following topics in very roughly the following order: * Basic philosophy of the course + why learn programming languages + what's a programming language? (or, what's *not* a programming language?) + programs as interpreters, and input as programs + learning how to think about programs + declarative vs. imperative programming * Variable Binding, argument passing, expression evaluation, and data lifetimes. + binding vs. assignment, lexical scope pass-by-value vs. pass-by-reference + static, dynamic (stack), explicit (heap) and indefinite (garbage collected) extent + input/output and persistence * Higher-order procedures and mostly-functional programming. + first class procedures + higher-order procedures and procedural abstraction + procedures with side effects vs. true functions, and + reasoning about composition * Interpreting a programming language + an interpreter for Scheme, in Scheme + interpretation vs. compilation * Dynamic vs. Static Typing. + type conformance * Extensible programming Languages + introduction to macros and code transformation * Object-Oriented Programming + interfaces and encapsulation + implementation and inheritance + classes and inheritance vs. prototypes and delegation + subtyping vs. subclassing + covariance and contravariance + multimethods and multiple dispatch + multiple inheritance * Compiling a programming language + a simple compiler for Scheme, in Scheme * Parameterized Type systems + conventional parameterized types + C++ templates + more powerful parameterization systems * Functional Programming + laziness, pass-by-name, and pass-by-need + representing state in a stateless language * Declarative programming + logic programming + prolog vs. theorem provers + database languages and query languages + constraint satisfaction * Concurrency + threads + parallelism * Distribution + client-server + message passing and RPC's + distributed object models and distributed shared memory * Extensible, Meta-Level, and Transformational Programming + extension and scripting languages + extensible languages, meta-level programing, and reflection.