IUCompilerCourse / Essentials-of-Compilation

A book about compiling Racket and Python to x86-64 assembly
1.27k stars 137 forks source link

Ch. 7 Python comments #146

Closed AndrewTolmach closed 1 year ago

AndrewTolmach commented 1 year ago

A few misc. questions that arose. (I made a version of the code that takes the opposite choices on these things)

jsiek commented 1 year ago
  1. Tuples are immutable in Python. The challenge section introduces the Python list type, which is mutable, and also introduces subscript assignment.
  2. That's a good point. It didn't occur to me that RCO would handle the issue regarding the initializing expressions. I've added a sentence saying expose_allocation can go before or after RCO.
  3. Looks like there was no good reason. I've switched GlobalValue to atomic. Thanks!