From 4fb9b3ec29c4212ad327dd8c6fa865e44013d13a Mon Sep 17 00:00:00 2001 From: Alex Knauth Date: Fri, 19 Aug 2016 20:16:40 -0400 Subject: [PATCH] use `lang-reader-module-paths` instead of copy-pasted code (#3) Relies on https://github.com/racket/racket/commit/42dcc525b1e03ca36488b815b45428655fdcbf1b --- 2d-lib/info.rkt | 2 +- 2d-lib/lang/reader.rkt | 10 +--------- 2 files changed, 2 insertions(+), 10 deletions(-) diff --git a/2d-lib/info.rkt b/2d-lib/info.rkt index e554a44..51bbe13 100644 --- a/2d-lib/info.rkt +++ b/2d-lib/info.rkt @@ -2,7 +2,7 @@ (define collection "2d") (define version "1.1") -(define deps '("base" +(define deps '(["base" #:version "6.6.0.3"] "scribble-lib" "syntax-color-lib")) (define pkg-desc "Implementation (no documentation) part of \"2d\"") diff --git a/2d-lib/lang/reader.rkt b/2d-lib/lang/reader.rkt index 0304ad0..889881f 100644 --- a/2d-lib/lang/reader.rkt +++ b/2d-lib/lang/reader.rkt @@ -15,15 +15,7 @@ (make-meta-reader '2d "language path" - (lambda (bstr) - (let* ([str (bytes->string/latin-1 bstr)] - [sym (string->symbol str)]) - (and (module-path? sym) - (vector - ;; try submod first: - `(submod ,sym reader) - ;; fall back to /lang/reader: - (string->symbol (string-append str "/lang/reader")))))) + lang-reader-module-paths wrap-reader wrap-reader (lambda (proc)