macro-debugger: workaround for instrumentation problem in provide
The expansion observer is not propagated to expand_all_provides. original commit: e13cce267d4f37242d494fc2dcba6a5ff4408c19
This commit is contained in:
parent
b4086e0783
commit
7baa54e6b1
|
@ -288,10 +288,23 @@
|
||||||
[() #f]
|
[() #f]
|
||||||
[((? CheckImmediateMacro)) $1])
|
[((? CheckImmediateMacro)) $1])
|
||||||
|
|
||||||
|
;; FIXME: workaround for problem in expander instrumentation:
|
||||||
|
;; observer not propagated correctly to expand_all_provides
|
||||||
|
;; so local actions that should be within prim-provide's EE
|
||||||
|
;; instead appear directly here
|
||||||
(Prim#%ModuleBegin
|
(Prim#%ModuleBegin
|
||||||
|
(#:args e1 e2 rs)
|
||||||
|
[(prim-#%module-begin ! rename-one (? ModuleBegin/Phase) (? Eval))
|
||||||
|
(make p:#%module-begin e1 e2 rs $2 $3 $4
|
||||||
|
(for/or ([la (in-list $5)])
|
||||||
|
(and (local-exn? la) (local-exn-exn la))))])
|
||||||
|
#|
|
||||||
|
;; restore this version when expander fixed
|
||||||
|
(Prim#%ModuleBegin-REAL
|
||||||
(#:args e1 e2 rs)
|
(#:args e1 e2 rs)
|
||||||
[(prim-#%module-begin ! rename-one (? ModuleBegin/Phase) !)
|
[(prim-#%module-begin ! rename-one (? ModuleBegin/Phase) !)
|
||||||
(make p:#%module-begin e1 e2 rs $2 $3 $4 $5)])
|
(make p:#%module-begin e1 e2 rs $2 $3 $4 $5)])
|
||||||
|
|#
|
||||||
|
|
||||||
(ModuleBegin/Phase
|
(ModuleBegin/Phase
|
||||||
[((? ModulePass1) next-group (? ModulePass2) next-group (? ModulePass3))
|
[((? ModulePass1) next-group (? ModulePass2) next-group (? ModulePass3))
|
||||||
|
|
|
@ -215,4 +215,12 @@
|
||||||
(syntax-local-value (quote-syntax lambda) void)))))])
|
(syntax-local-value (quote-syntax lambda) void)))))])
|
||||||
(check-pred deriv? d)
|
(check-pred deriv? d)
|
||||||
(check-pred ok-node? d)))
|
(check-pred ok-node? d)))
|
||||||
|
(test-case "syntax-local-value in provide"
|
||||||
|
(let ([d (trace '(module m racket/base
|
||||||
|
(#%plain-module-begin
|
||||||
|
(provide (except-out (all-defined-out) x y))
|
||||||
|
(define-values (x) 1)
|
||||||
|
(define-values (y) 2))))])
|
||||||
|
(check-pred deriv? d)
|
||||||
|
(check-pred ok-node? d)))
|
||||||
))
|
))
|
||||||
|
|
Loading…
Reference in New Issue
Block a user