compiler: fix inlining of #%variable-reference
This commit is contained in:
parent
486debd704
commit
719917f812
|
@ -4525,6 +4525,17 @@
|
|||
(f i #f))))
|
||||
(collect-garbage)
|
||||
|
||||
;; ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
|
||||
;; Check that `#%variable-reference` inlines ok:
|
||||
|
||||
(let ([go
|
||||
(lambda ()
|
||||
(define foo 3)
|
||||
(#%variable-reference foo))])
|
||||
(define v (list (go) (go)))
|
||||
(set! v v)
|
||||
(test '(#t #t) map variable-reference? v))
|
||||
|
||||
;; ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
|
||||
|
||||
(report-errs)
|
||||
|
|
|
@ -4343,7 +4343,7 @@ ref_clone(int dup_ok, Scheme_Object *data, Optimize_Info *info, int delta, int c
|
|||
if (!a) return NULL;
|
||||
|
||||
b = SCHEME_PTR2_VAL(data);
|
||||
b = optimize_clone(dup_ok, a, info, delta, closure_depth);
|
||||
b = optimize_clone(dup_ok, b, info, delta, closure_depth);
|
||||
if (!b) return NULL;
|
||||
|
||||
naya = scheme_alloc_object();
|
||||
|
|
Loading…
Reference in New Issue
Block a user