fix sequences

This commit is contained in:
Jon Rafkind 2011-07-14 16:53:00 -06:00
parent a29d64b44a
commit 3736571ad0
4 changed files with 13 additions and 2 deletions

View File

@ -9,6 +9,9 @@
print print
(rename-out [#%dynamic-honu-module-begin #%module-begin] (rename-out [#%dynamic-honu-module-begin #%module-begin]
[honu-function function] [honu-function function]
[honu-var var]
[literal:honu-= =]
[literal:semicolon |;|]
[literal:#%braces #%braces] [literal:#%braces #%braces]
[literal:#%parens #%parens]) [literal:#%parens #%parens])
) )

View File

@ -135,6 +135,13 @@
(lambda (x) x) (lambda (x) x)
(left current)))] (left current)))]
[(semicolon? #'head) [(semicolon? #'head)
(do-parse #'(rest ...) 0
(lambda (stuff)
(with-syntax ([stuff stuff]
[current (left current)])
#'(begin current stuff)))
#'(void))
#;
(with-syntax ([so-far (left current)]) (with-syntax ([so-far (left current)])
#'(splicing-let-syntax ([more (lambda (stx) #'(splicing-let-syntax ([more (lambda (stx)
(parse #'(rest ...)))]) (parse #'(rest ...)))])

View File

@ -16,13 +16,13 @@ function test(t, a, b){
*/ */
function test1(){ function test1(){
print(5)
/*
var x = 3; var x = 3;
/*
const y = 2; const y = 2;
test("x = 3", x, 3); test("x = 3", x, 3);
test("y = 2", y, 2); test("y = 2", y, 2);
*/ */
print(x)
} }
test1() test1()

View File

@ -47,6 +47,7 @@
(let () (let ()
(fake-module-begin #hx(honu_function test(x){ (fake-module-begin #hx(honu_function test(x){
print(x);
print(x) print(x)
} }
test(2)))) test(2))))