Lambda Bound University of British Columbia, Department of Computer Science
CPSC 311 Definition of Programming Languages
Winter 2015 Term 1

Course Goals     Syllabus     Notes     Assignments         Piazza    

Lectures

Lectures will involve a mix of coding from my laptop, the whiteboard or camera projector, and (occasionally) slides. Code and slides will be posted before, or shortly after, lectures. For whiteboard-based lectures, lecture notes will usually be posted later the same day. If I use the camera projector, scans will usually be posted later the same day.

Note: To "skim" means to go through once: "eyes meet the page". To "read" means to carefully inspect with a pen (or physical/digital equivalent) in hand; jot down, look up, and answer questions; work exercises; and generally interrogate the material.

Warning

This schedule is a work in progress. Topics may be expanded, moved, or dropped at short notice.

 datesubjectmaterialsreading for next lecture
Wednesday,
Sept. 9
Introduction:
Defining
"Definition of
Programming Languages"
slides
"The C language does not exist" (from UBC net)
Skim Chapter 1
and Chapter 2.
Skim Intermezzo: BSL from HtDP.
Friday,
Sept. 11
Racket;
syntax and parsing
lec2.rkt: Racket basics
lec2a.rkt: BNF and define-type
Read Chapter 1
and Chapter 2.
Play around with DrRacket.
 
Monday,
Sept. 14
Syntax (wrap-up);
parsing; type-case
lec2a.rkt; lec3_parsing.pdf Skim Chapter 3
and (maybe) Chapter 4.
Part 1: Dynamic semantics
Wednesday,
Sept. 16
Identifiers and substitution slides;
lec4_let.pdf (and Racket Guide);
lec4.rkt
Friday,
Sept. 18
Evaluation semantics
including with
(and substitution)
04-operational.pdf;
dynsem.rkt
Read 04-operational.pdf
 
Monday,
Sept. 21
Finishing up with;
Functions
dynsem-with.rkt
06-functions.pdf
Wednesday,
Sept. 23
(continued)
06-functions.pdf Read 06-functions.pdf
Friday,
Sept. 25
Functions;
unparsing;
[recursion]
08-morefunctions.pdf
dynsem-fun.rkt
Read 08-morefunctions.pdf
 
Monday,
Sept. 28
Recursion; conditionals;
syntactic sugar;
Assignment 2 preview
08-morefunctions.pdf
Wednesday,
Sept. 30
no lecture :-( 10-contexts.pdf
Friday,
Oct. 2
Error handling and
small-step semantics
10-contexts.pdf
smallstep.rkt
tutorialoct52015.rkt
 
Monday,
Oct. 5
Classifying languages 11-taxonomy.pdf
Wednesday,
Oct. 7
Review if0, define vs. rec: a2-morefun-if0.rkt
paircase: paircase.rkt
subst: 2015-10-07-subst.pdf
Part 2: Static semantics
Friday,
Oct. 9
Types 12-types.pdf Read Section 1, Cardelli, Type Systems
Read 12-types.pdf
 
Monday,
Oct. 12
Thanksgiving (no class)
Wednesday,
Oct. 14
Typing for [[B]W]AE 13-typing-rules.pdf
typing-with.rkt
Friday,
Oct. 16
modes;
typing lam
13-typing-rules.pdf
typing-lam.rkt (with a recipe)
 
Monday,
Oct. 19
Review:
BNF, rules, evaluation
14-review.pdf
Tutorial notes:
tutorialoct192015.rkt,
...syntacticsugarwith.rkt
Wednesday,
Oct. 21
Strings 15-strings.pdf
typing-strings.rkt
Friday,
Oct. 23
Type safety 15-strings.pdf
typing-strings.rkt
practice midterm:
practice-blank.pdf
 
Monday,
Oct. 26
Review
for midterm
16-review.pdf
visible-interp.rkt
solution to
practice midterm:
practice-sol.pdf
Wednesday,
Oct. 28
Review
for evening midterm
(MIDTERM:
18:30 (6:30pm),
SWNG 121, 122)
16-review.pdf
value-expr.rkt
Friday,
Oct. 30
Polymorphism 17-polymorphism.pdf
17-poly.sml
Part 3: Practical dynamic semantics
Monday,
Nov. 2
Environment-based evaluation
18-env.pdf
env-with-broken.rkt
18-env.pdf
env-with.rkt
tutorials,
Nov. 2
Polymorphism for Fun tutorial-2015-11-02.rkt
Wednesday,
Nov. 4
Environment-based evaluation:
closures
19-closures.pdf
env-with-extended.rkt
Friday,
Nov. 6
Environment-based evaluation:
recursion
19-closures.pdf
env-fun.rkt
Part 4: Everything else
Monday,
Nov. 9
Mutable state 20-state.pdf
env-state.rkt (without using Racket boxes)
env-state-direct.rkt (using Racket boxes)
20-state.pdf
tutorials,
Nov. 9
Free variable checking;
closures
dynamic-scope.el
lexical-scope.rkt
dynsem-fun-tutorial.rkt
env-fun-tutorial.rkt
Wednesday,
Nov. 11
Remembrance Day (no class)
Friday,
Nov. 13
Lazy evaluation 21-lazy.pdf
env-thunks.rkt
 
Monday,
Nov. 16
Subtyping typing reminder: a3solution.rkt
new stuff: 22-subtyping.pdf
subtyping.rkt
tutorials,
Nov. 16
Lazy evaluation
tutorial-laziness-2015-11-16.rkt
Wednesday,
Nov. 18
Subtyping (continued) stuff updated since Monday: 22-subtyping.pdf
subtyping.rkt (updated)
Friday,
Nov. 20
Subtyping (continued);
downcasts
updated again: 22-subtyping.pdf
subtyping.rkt
scanned notes
typeset addendum to the scanned notes
optional a4 has been posted
 
Monday,
Nov. 23
Small-step:
review and par (a4)
scanned notes
tutorials,
Nov. 23

Wednesday,
Nov. 25
Type inference 24-type-inference.pdf
type-inference.rkt
Friday,
Nov. 27
Bidirectional typing 25-bidirectional.pdf
bidirectional.rkt
 
Monday,
Nov. 30
Review:
derivations,
lexical scope and closures,
dynamic semantics
scanned notes
flip-env.rkt, flip-typeof.rkt
Review all the term's readings.
tutorials,
Nov. 30
dynamic scope,
stepping
tutorial-2015-11-30-subtyping.rkt (dynamic scope)
tutorial-2015-11-30-step.rkt
Wednesday,
Dec. 2
Review a4sol.rkt
a4-stepsol.rkt
scan-2015-12-02-bidirectional.pdf
Review all the term's readings.
Friday,
Dec. 4
YOUR Poster Session Be prepared to do your peer reviews! Review all the term's readings.
Final Preparation Practice Final—Episode One 311-practicefinal-blank.pdf
311-practicefinal-solution.pdf
scan-practicefinalQ1a.pdf