Class 16: Scheme Semantics (2)

Back to Scheme Semantics (1). On to Program Verification.

Held Monday, March 1

Summary

Contents

Handouts

Notes

• Once again, the emphasis will be on recitation rather than lecture.
• I know we could go faster if I lectured, but I care that you learn how to read this stuff, and I think you learn that better through this mode of teaching.
• I've updated assignment 3. (Took away all the problems on the Scheme semantics.)
• I've been asked to remind you that a forthcoming convo speaker does cool work in statistics. Talk to Mr. Moore today if you'd be interested in meeting with him for lunch after convo.

Review and such

Typography

• Capital Greek letters are used for syntactic variables
• I'll try to use italic uppercase in the web page
• Three-letter combinations are used for syntactic domains
• Multi-letter typewriter face is used for syntactic constants
• Single-letter typewriter face is used for semantic domains
• Lowercase Greek letters are used for semantic variables
• I'll try to use italic lowercase in the web page
• Italicized Roman words are used for semantic constants and helper functions
• Capital script letters are used for semantic functions
• I'll try to use bold in the web page

Questions

These are the questions I received via e-mail. I assume answers to a general audience are appropriate.

• Why is it that send : E -> K -> C and single : (E -> C) -> K? That is, why the odd parenthesization?
• There is different parenthesization in single because right-arrow is right-associative. That is, send takes an E and returns a function from K to C. single, on the other hand, takes a function from E to C and returns a K.
• What is that weirdo symbol in the definition of single?
• Since there is no semantic domain that corresponds to (E -> C), they use a different Greek letter as a variable.
• What is an answer (A)?
• Answers appear to be purposefully undefined. They are "what the Scheme interpreter gives back after reading an expression".

New Topics

Domains

• What are the ``x `T`'' thingamabobs doing in the definitions of the various `E`s?
• You can make some guesses.
• How might you test your guesses?
• What do you obseve about environments in the Scheme semantics (particularly as compared to the SIMPLE semantics)?
• What's the ``x `T`'' doing in the definition of `S`?

Semantic Functions

• Why does every meaning function seem to return a `C`?
• E[[K]] = \u k . send (K[[K]]) k
• Why does E seem to take only one argument, given that it's type is Exp -> `U` -> `K` -> `C`
• What does send do?
• What happened to u?
• What does this say?
• Now do you see why I said that it will take awhile to read the semantics of Scheme?

History

• Created Tuesday, January 19, 1999 as a blank outline.
• Filled in the details on Sunday, February 28, 1999. (Taken from a previous outline.)

Back to Scheme Semantics (1). On to Program Verification.

Disclaimer Often, these pages were created ``on the fly'' with little, if any, proofreading. Any or all of the information on the pages may be incorrect. Please contact me if you notice errors.