IUCompilerCourse / public-student-support-code

Public helper code for p423/p523 students (Racket)
MIT License
155 stars 74 forks source link

utilties.rkt function parses incorrectly when using book. #10

Open pyrofolium opened 2 years ago

pyrofolium commented 2 years ago

When I run this:

(require "utilities.rkt")

(define x (parse-program `(program () (+ 10 (- (+ 5 3))))))

(define y
  (Program '() (Prim '+ (list (Int 10) (Prim '- (list (Prim '+ (list (Int 5) (Int 3))))))

the values on the repl display different things for y and x. In fact the interp-Rint function in the book actually can't parse x. If users follow the book it doesn't exactly work..?