[honu] expand honu's #%top-interaction to racket's #%top-interaction

This commit is contained in:
Jon Rafkind 2011-09-06 16:54:56 -06:00
parent d53332c1f7
commit 6bf5d43c37
3 changed files with 5 additions and 2 deletions

View File

@ -457,7 +457,9 @@ Then, in the pattern above for 'if', 'then' would be bound to the following synt
[(_) #'(void)]
[(_ forms ...)
(define-values (parsed unparsed) (honu-expand #'(forms ...)))
(debug "expanded ~a\n" (syntax->datum parsed))
(debug "expanded ~a unexpanded ~a\n"
(syntax->datum parsed)
(syntax->datum unparsed))
(with-syntax ([parsed parsed]
[(unparsed ...) unparsed])
(if (null? (syntax->datum #'(unparsed ...)))

View File

@ -165,4 +165,4 @@
(define-syntax (honu-top-interaction stx)
(syntax-case stx ()
[(_ rest ...)
#'(printf "~a\n" (honu-unparsed-begin rest ...))]))
#'(#%top-interaction . (honu-unparsed-begin rest ...))]))

View File

@ -6,6 +6,7 @@ honu
#:read-syntax honu-read-syntax
#:whole-body-readers? #t
#:info honu-info
#:language-info #(honu/core/language honu-language-info #f)
(require "../core/read.rkt"
"../core/language.rkt")