bytecode compiler: fix misuse of "optimize" mode on a "resolved" form
Thanks to Robby for the test.
This commit is contained in:
parent
736cdfb2c1
commit
aead07b5de
|
@ -5759,6 +5759,12 @@
|
|||
(parameterize ([read-accept-compiled #t])
|
||||
(void (read (open-input-bytes (get-output-bytes o))))))
|
||||
|
||||
;; ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
|
||||
;; Check for an optimizer regresssion
|
||||
|
||||
(err/rt-test (+ (let-values (((x y) (let-values ((() 9)) 2))) x) (error))
|
||||
exn:fail?)
|
||||
|
||||
;; ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
|
||||
|
||||
(report-errs)
|
||||
|
|
|
@ -512,7 +512,7 @@ static Scheme_Object *look_for_letv_change(Scheme_Sequence *s)
|
|||
v = s->array[i];
|
||||
if (SAME_TYPE(SCHEME_TYPE(v), scheme_let_value_type)) {
|
||||
Scheme_Let_Value *lv = (Scheme_Let_Value *)v;
|
||||
if (scheme_omittable_expr(lv->body, 1, -1, 0, NULL, NULL)) {
|
||||
if (scheme_omittable_expr(lv->body, 1, -1, OMITTABLE_RESOLVED, NULL, NULL)) {
|
||||
int esize = s->count - (i + 1);
|
||||
int nsize = i + 1;
|
||||
Scheme_Object *nv, *ev;
|
||||
|
|
Loading…
Reference in New Issue
Block a user