scribble/eval: change string or byte-string expression handling
Use `datum->syntax' instead of `begin' to protect the string or byte string. Danny Yoo suggested this change. original commit: 23296615ec7cddb34257486b62094048b085ff6e
This commit is contained in:
parent
2c0f9c9480
commit
548627c404
|
@ -372,8 +372,10 @@
|
|||
(syntax-case s (module)
|
||||
[(module . _rest) (syntax->datum s)]
|
||||
[_else s])]
|
||||
[(bytes? s) `(begin ,s)]
|
||||
[(string? s) `(begin ,s)]
|
||||
;; a sandbox treats strings and byte strings as code
|
||||
;; streams, so protect them as syntax objects:
|
||||
[(string? s) (datum->syntax #f s)]
|
||||
[(bytes? s) (datum->syntax #f s)]
|
||||
[else s]))))
|
||||
list)))
|
||||
|
||||
|
|
Loading…
Reference in New Issue
Block a user