*** empty log message ***

original commit: 65d66e4bc44b3d24ded43a8437fc019cdf9043c7
tokens
Scott Owens 20 years ago
parent d3ed80f6c8
commit 982dba75db

@ -64,7 +64,7 @@
(define (display-yacc grammar tokens start precs port)
(let-syntax ((p (syntax-rules ()
((_ args ...) (fprintf port args ...)))))
(let* ((tokens (map syntax-local-value (cdr (syntax->list tokens))))
(let* ((tokens (map syntax-local-value (syntax->list tokens)))
(eterms (filter e-terminals-def? tokens))
(terms (filter terminals-def? tokens))
(term-table (make-hash-table))
@ -97,7 +97,7 @@
(p " ~a" (hash-table-get term-table tok)))
(cdr prec))
(p "~n"))
(cdr precs)))
precs))
(p "%start ~a~n" start)
(p "%%~n")
@ -110,7 +110,7 @@
(display-rhs rhs))
(cddr prod))
(p ";~n")))
(cdr grammar))
grammar)
(p "%%~n"))))

Loading…
Cancel
Save