reader: source location for #lang language

This commit is contained in:
Matthew Flatt 2018-03-01 09:40:33 -07:00
parent a668a6a674
commit ae0ce206f8

View File

@ -74,6 +74,8 @@
(reader-error in config (reader-error in config
"`~a` not enabled" "`~a` not enabled"
extend-str)) extend-str))
(define-values (line col pos) (port-next-location in))
(define accum-str (accum-string-init! config)) (define accum-str (accum-string-init! config))
(when init-c (when init-c
@ -121,7 +123,7 @@
(define reader-path (string->symbol (string-append lang-str "/lang/reader"))) (define reader-path (string->symbol (string-append lang-str "/lang/reader")))
(read-extension #:try-first-mod-path submod-path (read-extension #:try-first-mod-path submod-path
reader-path read-recur in config reader-path read-recur in (reading-at config line col pos)
#:get-info? get-info? #:get-info? get-info?
#:who who)) #:who who))
@ -158,7 +160,7 @@
((read-config-coerce config) ((read-config-coerce config)
#t #t
mod-path-datum mod-path-datum
#f)] (port+config->srcloc in config))]
#:get-info? [get-info? #f] #:get-info? [get-info? #f]
#:who [who '|#reader|]) #:who [who '|#reader|])
(force-parameters! config) (force-parameters! config)