fix lazy stepper bug: annota of non-identifier fns
- fix lazy stepper bug where delaying of non-identifier fns
wasnt being properly hidden
- add test case for this bug
include in 5.2
(cherry picked from commit 79dd7df945
)
This commit is contained in:
parent
fcd5fb9d74
commit
d2204bfd17
|
@ -78,7 +78,10 @@
|
|||
|
||||
(define-syntax (mark-as-lazy-op stx)
|
||||
(syntax-case stx ()
|
||||
[(_ arg) (stepper-add-lazy-op-prop (syntax/loc stx arg))]))
|
||||
[(_ arg)
|
||||
(identifier? #'arg)
|
||||
(stepper-add-lazy-op-prop (syntax/loc stx arg))]
|
||||
[(_ arg) #'arg]))
|
||||
|
||||
(define-syntax (hidden-~ stx)
|
||||
(syntax-case stx ()
|
||||
|
|
|
@ -23,7 +23,7 @@
|
|||
lazy-length lazy-list-ref lazy-list-tail lazy-append lazy-reverse lazy-empty?
|
||||
lazy-assoc lazy-assq lazy-assv lazy-cons? lazy-remove lazy-remq lazy-remv
|
||||
lazy-member lazy-memq lazy-memv lazy-filter1 lazy-filter2 lazy-fold
|
||||
lazy-cyclic1))
|
||||
lazy-cyclic1 lazy-fn-app))
|
||||
|
||||
(let ((outer-namespace (current-namespace)))
|
||||
(parameterize ([display-only-errors #t]
|
||||
|
|
|
@ -2132,8 +2132,16 @@
|
|||
-> ,def (+ 1 {1})
|
||||
:: ,def {(+ 1 1)} -> ,def {2}))
|
||||
|
||||
|
||||
|
||||
; application in function position -- checks bug fix
|
||||
(let* ([lxx '(lambda (x) x)]
|
||||
[def `(define I ,lxx)])
|
||||
(t 'lazy-fn-app m:lazy
|
||||
,def ((I I) I)
|
||||
:: ,def (({I} I) I) -> ,def (({,lxx} I) I)
|
||||
:: ,def ((,lxx {I}) I) -> ,def ((,lxx {,lxx}) I)
|
||||
:: ,def ({(,lxx ,lxx)} I) -> ,def ({,lxx} I)
|
||||
:: ,def (,lxx {I}) -> ,def (,lxx {,lxx})
|
||||
:: ,def {(,lxx ,lxx)} -> ,def {,lxx}))
|
||||
|
||||
|
||||
#;
|
||||
|
|
Loading…
Reference in New Issue
Block a user