diff --git a/collects/typed-scheme/optimizer/unboxed-let.rkt b/collects/typed-scheme/optimizer/unboxed-let.rkt index 04cc64051e..4034924fc4 100644 --- a/collects/typed-scheme/optimizer/unboxed-let.rkt +++ b/collects/typed-scheme/optimizer/unboxed-let.rkt @@ -155,7 +155,9 @@ #:literal-sets (kernel-literals) #:attributes ([key 1] kw) (pattern (~and kw (~literal let-values)) - #:with (key ...) #'(kw)) + ;; we need let*-values because we bind intermediate unboxed results, + ;; and the bindings for the final results refer to them + #:with (key ...) #'(let*-values)) (pattern (~and kw (~literal letrec-values)) #:with (key ...) #'(kw)) (pattern (~seq (~and kw (~literal letrec-syntaxes+values)) stx-bindings)