* Kind of fixes bug 163219: Better error message for expand.

This commit is contained in:
Abdulaziz Ghuloum 2007-11-18 19:10:03 -05:00
parent e99ce9c03b
commit 442eb1ca00
2 changed files with 22 additions and 6 deletions

View File

@ -2369,7 +2369,16 @@
(stx-error e "identifier out of context")) (stx-error e "identifier out of context"))
((syntax) (stx-error e "reference to pattern variable outside a syntax form")) ((syntax) (stx-error e "reference to pattern variable outside a syntax form"))
((define define-syntax module import library) ((define define-syntax module import library)
(stx-error e "invalid expression")) (stx-error e
(string-append
(case type
((define) "a definition")
((define-syntax) "a define-syntax")
((module) "a module definition")
((library) "a library definition")
((import) "an import declaration")
(else "a non-expression"))
" was found where an expression was expected")))
(else (else
;(error 'chi-expr "invalid type " type (strip e '())) ;(error 'chi-expr "invalid type " type (strip e '()))
(stx-error e "invalid expression")))))) (stx-error e "invalid expression"))))))

View File

@ -917,11 +917,18 @@
(library-info (car x)))) (library-info (car x))))
library-names) library-names)
(printf "Status Codes:\n") (printf "Status Codes:\n")
(for-each (let* ([s* (map
(lambda (x) (lambda (x)
(printf " ~a ~a (~s ids)\n" (car x) (cadr x) (count-status (car x)))
(count-status (car x)))) status-names)]
status-names)] [all (apply + s*)])
(for-each
(lambda (x s)
(printf " ~a ~a (~s ids == ~s%)\n"
(car x) (cadr x)
s
(/ (round (* (/ s all) 10000)) 100.0)))
status-names s*))]
[else [else
(let-values ([(s* l*) (let-values ([(s* l*)
(split (split