repair for re-expansion of an implicit-form expansion
The repair in 385f9588f8
propagates the
must-be-bound callback too far. It shouldn't be propagated anymore after
a non-rename transformer is applied.
Closes #2048
This commit is contained in:
parent
53c1b5b1db
commit
6f31650539
|
@ -1950,6 +1950,16 @@
|
||||||
(let-syntax ([#%datum (make-rename-transformer #'unbound)])
|
(let-syntax ([#%datum (make-rename-transformer #'unbound)])
|
||||||
(+ 1 2))))
|
(+ 1 2))))
|
||||||
|
|
||||||
|
(module make-sure-not-bound-as-syntax-is-not-propagated-to-reexpansion racket/base
|
||||||
|
(module new-top racket/base
|
||||||
|
(provide #%top)
|
||||||
|
(define (helper sym) sym)
|
||||||
|
(define-syntax-rule (#%top . ID)
|
||||||
|
(helper 'ID)))
|
||||||
|
|
||||||
|
(local-require (submod 'new-top))
|
||||||
|
foobar)
|
||||||
|
|
||||||
;; ----------------------------------------
|
;; ----------------------------------------
|
||||||
;; Check that definition context bindings are made available when the context is provided as fourth
|
;; Check that definition context bindings are made available when the context is provided as fourth
|
||||||
;; argument of syntax-local-bind-syntaxes
|
;; argument of syntax-local-bind-syntaxes
|
||||||
|
|
|
@ -322,7 +322,7 @@
|
||||||
id))
|
id))
|
||||||
#:skip-log? (or (expand-context-only-immediate? ctx)
|
#:skip-log? (or (expand-context-only-immediate? ctx)
|
||||||
(rename-transformer? t))
|
(rename-transformer? t))
|
||||||
#:fail-non-transformer fail-non-transformer)])]))
|
#:fail-non-transformer (and (rename-transformer? t) fail-non-transformer))])]))
|
||||||
|
|
||||||
;; Handle the expansion of a variable to itself
|
;; Handle the expansion of a variable to itself
|
||||||
(define (dispatch-variable t s id ctx binding primitive? protected?)
|
(define (dispatch-variable t s id ctx binding primitive? protected?)
|
||||||
|
|
|
@ -39985,11 +39985,12 @@ static const char *startup_source =
|
||||||
"(let-values(((or-part_263)"
|
"(let-values(((or-part_263)"
|
||||||
"(expand-context-only-immediate? ctx_23)))"
|
"(expand-context-only-immediate? ctx_23)))"
|
||||||
"(if or-part_263 or-part_263(1/rename-transformer? t_53))))"
|
"(if or-part_263 or-part_263(1/rename-transformer? t_53))))"
|
||||||
"((fail-non-transformer199_0) fail-non-transformer_4))"
|
"((temp199_0)"
|
||||||
|
"(if(1/rename-transformer? t_53) fail-non-transformer_4 #f)))"
|
||||||
"(expand9.1"
|
"(expand9.1"
|
||||||
" temp197_0"
|
" temp197_0"
|
||||||
" #t"
|
" #t"
|
||||||
" fail-non-transformer199_0"
|
" temp199_0"
|
||||||
" #t"
|
" #t"
|
||||||
" temp198_0"
|
" temp198_0"
|
||||||
" #t"
|
" #t"
|
||||||
|
|
Loading…
Reference in New Issue
Block a user