Merge pull request #244 from picrin-scheme/better-error-message

better error messages against invalid use of auxiliary syntax
This commit is contained in:
Yuichi Nishiwaki 2015-01-19 16:21:54 +09:00
commit 9d2ed448fe
2 changed files with 3 additions and 3 deletions

View File

@ -52,7 +52,7 @@ my $src = <<'EOL';
(list (r 'define-syntax) (cadr expr)
(list (r 'lambda) '_
(list (r 'lambda) '_
(list (r 'error) "invalid use of auxiliary syntax")))))))
(list (r 'error) (list (r 'string-append) "invalid use of auxiliary syntax: '" (symbol->string (cadr expr)) "'"))))))))
(define-auxiliary-syntax else)
(define-auxiliary-syntax =>)
@ -452,7 +452,7 @@ const char pic_boot[] =
" (list (r 'define-syntax) (cadr expr)\n"
" (list (r 'lambda) '_\n"
" (list (r 'lambda) '_\n"
" (list (r 'error) \"invalid use of auxiliary syntax\")))))))\n"
" (list (r 'error) (list (r 'string-append) \"invalid use of auxiliary syntax: '\" (symbol->string (cadr expr)) \"'\"))))))))\n"
"\n"
" (define-auxiliary-syntax else)\n"
" (define-auxiliary-syntax =>)\n"

View File

@ -8,7 +8,7 @@
(list (r 'define-syntax) (cadr expr)
(list (r 'lambda) '_
(list (r 'lambda) '_
(list (r 'error) "invalid use of auxiliary syntax")))))))
(list (r 'error) (list (r 'string-append) "invalid use of auxiliary syntax: '" (symbol->string (cadr expr)) "'"))))))))
(define-auxiliary-syntax _)
(define-auxiliary-syntax ...)