missing library file errors now print import trace.

This commit is contained in:
Abdulaziz Ghuloum 2009-01-03 20:23:33 -05:00
parent 1ebd4f4d9a
commit 71c707df50
3 changed files with 15 additions and 6 deletions

View File

@ -1 +1 @@
1738
1739

View File

@ -37,20 +37,24 @@
source.\n"
name depname filename))
(define (file-locator-resolution-error libname failed-list)
(define (file-locator-resolution-error libname failed-list pending-list)
(define-condition-type &library-resolution &condition
make-library-resolution-condition
library-resolution-condition?
(library condition-library)
(files condition-files))
(define-condition-type &imported-from &condition
make-imported-from-condition imported-from-condition?
(importing-library importing-library))
(raise
(condition
(make-error)
(apply condition (make-error)
(make-who-condition 'expander)
(make-message-condition
"cannot locate library in library-path")
(make-library-resolution-condition
libname failed-list))))
libname failed-list)
(map make-imported-from-condition pending-list))))
(define-syntax define-record
(syntax-rules ()

View File

@ -141,7 +141,12 @@
(failed-list '()))
(cond
((null? ls)
(file-locator-resolution-error x (reverse failed-list)))
(file-locator-resolution-error x
(reverse failed-list)
(let ([ls (external-pending-libraries)])
(if (null? ls)
(error 'library-manager "BUG")
(cdr ls)))))
((null? exts)
(f (cdr ls) (library-extensions) failed-list))
(else