commit bc29f1ca3cfbb4fdad42283693e6b3fd988303d6 parent aa3d449185b26360918f94731e8e2299c9d7a3ad Author: Matthew Flatt <mflatt@racket-lang.org> Date: Sun, 11 Apr 2010 16:55:18 +0000 module paths normalize to .rkt, load handler converts .rkt back to .ss if necessary svn: r18788 original commit: bdb71498e3ed816d44c9faf830f97fbe9fdaa3f2 Diffstat:
| M | collects/scribble/extract.ss | | | 10 | +++++++++- |
1 file changed, 9 insertions(+), 1 deletion(-)
diff --git a/collects/scribble/extract.ss b/collects/scribble/extract.ss @@ -23,7 +23,15 @@ [else c])) (define-for-syntax (extract orig-path stx) - (let ([path (resolve-path-spec orig-path orig-path stx)]) + (let* ([n-path (resolve-path-spec orig-path orig-path stx)] + [path (if (regexp-match? #rx#"[.]rkt$" (path->bytes n-path)) + (if (file-exists? n-path) + n-path + (let ([ss (path-replace-suffix n-path #".ss")]) + (if (file-exists? ss) + ss + n-path))) + n-path)]) (let ([s-exp (parameterize ([current-namespace (make-base-namespace)] [read-accept-reader #t]