August 23 (Thu), 2007 Syllabus, grading policy handouts (also on the web site). Presentation of course objectives. Questionnaire, with discussion. (Ghezzi and Jazayeri, parts of Ch.1) Note: problems with projector.
August 28 (Tue), 2007 Q1 Why study principles of PLs? HW1 assigned, due on Tuesday, September 4. Programming methodologies: waterfall, spiral, RUDE. Programming environments. Influences on PL design. (Ghezzi and Jazayeri, parts of Ch.1)
August 30 (Thu), 2007 Q2. Programming methodologies: waterfall, spiral, RUDE. Programming environments. Influences on PL design. Data and control abstraction. The von Neumann computer organization ("architecture") and its effect on PLs. Other architectures. Symbolics, Japanese fifth generation. Language translation: compilation, interpretation, hybrid. Genealogy of PLs. Features of three main families of PLs: imperative (or procedural or assignment-based), functional or applicative, logic or declarative. Some examples.
September 4 (Tue), 2007 Quizzes 3 and 4. (Lecturer: Mr. Sen Xu) HW1 collected. Ariane handout given. Syntax and Semantics: Introduction. Lexical analysis and syntactic analysis. BNF. Definitions and examples: sentence, sentential form, derivation, ambiguous grammar, with examples. EBNF.
September 6 (Thu), 2007 Q5. (Lecturer: Mr. Sen Xu) Scope rules. Attribute grammars, with example.
September 11 (Tue), 2007 No Quiz. HW2 assigned (due in one week) HW3 assigned (due on Thursday, September 20, 2007) Review of syntax. Lexical and syntactic analysis in the miniTriangle language, as an example. Dangling else problem.
September 13 (Thu), 2007 Q5. Binding times. Axiomatic semantics. Example of use of axiomatic semantics: a program with a while loop to compute the sum of consecutive integers.
September 18 (Tue), 2007 Q6 (as an in-class exercise). Axiomatic semantics, continued. Termination---the method of well-founded sets. Example of use of axiomatic semantics: variations on a program with a while loop to compute the sum of consecutive integers: defensive loop condition and its impact on the invariant. Accumulators.
September 20 (Thu), 2007 Q8. HW3 collected and discussed. Sample MT1 discussed, including static vs. dynamic scope. MT1 will be next Thursday. Denotational semantics---first page of handout.
September 25 (Tue), 2007 Backus tape on FP. (Sen Xu coordinates)
September 27 (Tue), 2007 MT1
October 2 (Tue), 2007 MT1 returned and discussed in detail. Denotational semantics: simple language fully discussed. Example (factorial with a while/do loop started).
October 4 (Thu), 2007 Q9. Denotational semantics, completed. Introduction to operational semantics and Simplesem.
October 9 (Tue), 2007 HW4 assigned, due October 16. Q10. Introduction to operational semantics. Introduction to Simplesem. Categorization of PLs by data memory use: static, stack-based, dynamic. C1 language, with Euclid's algorithm example. C2 language, with example.
October 16 (Tue), 2007 No quiz. HW4 collected. Static languages: C1, C2, C2'. Early Fortran as a "C2-class" language, with an example. Stack-dynamic languages. Introduction to C3. Example of direct recursion: comb (in ML). Example of indirect (mutual) recursion: take and skip (in ML).
October 18 (Thu), 2007 Q11. PR1 assigned, due on Thursday, October 25. C3.
October 23 (Tue), 2007 Q12. PR2 assigned, due on Tuesday, October 30. Review of C3. Block structure: C4, C4' (compound statements), C4'' (nested routines).
October 25 (Tue), 2007 Q13. PR1 due date delayed (to October 28) to have students prove correctness of the program, not just Euclid's property. C4''. Example of memory management for C4''.
October 30 (Tue), 2007 No quiz. Discussion of PR2 issues. PR2 due date delayed to November 1. C5': dynamic arrays. Parameter passing methods: by reference, value-result, name; first two described in depth with examples showing why their semantics are different.
November 1 (Thu), 2007 Q14. C5''" pointers. Semantics (lifetime) of dynamic variables. Pointers in C(++) and Pascal. The heap. Heap management, coalescing, compaction. Explicit storage deallocation. Garbage collection. The mark and sweep algorithm.
November 6 (Tue), 2007 No quiz. PR3 assigned, due Thursday, October 13 (on Backus's FP). FP, with examples, using Carter Bays's interpreter.
November 8 (Thu), 2007 Q15. MT2 will be one week from today (Thursday, November 15). FP examples: eq0, sub1, fact, ip. Haskell presentation (using slides).
November 13 (Tue), 2007 Q16. MT2 will cover semantics (from p.46 to the end of chapter 2 of [G&J] and FP. Introduction to ML.
November 15 (Thu), 2007 MT2.
November 20 (Tue), 2007 No quiz. HW5 assigned: Exercises 2.1.2, 2.2.2, 2.4.1, 2.4.3, 2.4.5, 2.4.6 [U] PR4 assigned: Exercises 2.1.1, 3.1.1, 3.1.2, 3.2.1 [U], both due on Thursday, November 29. SML has been installed on the linux machines: source /usr/local/etc/sml.bash or sml.csh MT2 returned. The ML type system. Tuples, lists. Simple functions in ML. Patterns. Simple recursive functions: factorial and list membership, with and without patterns.
November 27 (Tue), 2007 PR5 assigned: Exercises 3.3.1 (change "d" to "e" in part e; change "e" to "f" in part f), 3.3.2, 3.3.3, 3.3.11, 5.4.2, due December 4. PR6 assigned: Prolog assignment, due December 6. Mutual recursion: take and skip in ML. Recursive factorial, iterative factorial, tail recursive factorial, accumulators. Eager (strict) and lazy evaluation: the cond example.
November 29 (Thu), 2007 Q17. Naive and fast reverse (with an accumulator). Blocks in ML: let.
December 4 (Tue), 2007 Q18. Prolog.
December 6 (Thu), 2007 Q19. Student presentations. Student evaluation questionnaire. There will be a review session on Tuesday, Deceember 11, from 1045-1130 in 3A75