fixing a few type errors
This commit is contained in:
parent
446623f0c0
commit
e0429d565a
|
@ -101,7 +101,11 @@
|
||||||
[(ModuleSource? src)
|
[(ModuleSource? src)
|
||||||
(let ([name (rewrite-path (ModuleSource-path src))]
|
(let ([name (rewrite-path (ModuleSource-path src))]
|
||||||
[text (query:query `(file ,(path->string (ModuleSource-path src))))]
|
[text (query:query `(file ,(path->string (ModuleSource-path src))))]
|
||||||
|
[module-requires (query:lookup-module-requires (ModuleSource-path src))]
|
||||||
[bytecode (parse-bytecode (ModuleSource-path src))])
|
[bytecode (parse-bytecode (ModuleSource-path src))])
|
||||||
|
(log-debug "~a requires ~a"
|
||||||
|
(ModuleSource-path src)
|
||||||
|
module-requires)
|
||||||
(make-UninterpretedSource
|
(make-UninterpretedSource
|
||||||
(format "
|
(format "
|
||||||
MACHINE.modules[~s] =
|
MACHINE.modules[~s] =
|
||||||
|
|
|
@ -58,17 +58,21 @@
|
||||||
[(_ module-path ...)
|
[(_ module-path ...)
|
||||||
(andmap (lambda (p) (module-path? (syntax-e p)))
|
(andmap (lambda (p) (module-path? (syntax-e p)))
|
||||||
(syntax->list #'(module-path ...)))
|
(syntax->list #'(module-path ...)))
|
||||||
(syntax/loc stx
|
(with-syntax ([(required-path ...)
|
||||||
(begin
|
(map (lambda (p)
|
||||||
(begin-for-syntax
|
(my-resolve-path (syntax-e p)))
|
||||||
(let* ([this-module
|
(syntax->list #'(module-path ...)))])
|
||||||
(variable-reference->resolved-module-path
|
(syntax/loc stx
|
||||||
(#%variable-reference))]
|
(begin
|
||||||
[key (resolved-module-path-name this-module)])
|
(begin-for-syntax
|
||||||
(record-module-require! this-module 'module-path)
|
(let* ([this-module
|
||||||
...
|
(variable-reference->resolved-module-path
|
||||||
(void)))
|
(#%variable-reference))]
|
||||||
(void)))]
|
[key (resolved-module-path-name this-module)])
|
||||||
|
(record-module-require! key 'required-path)
|
||||||
|
...
|
||||||
|
(void)))
|
||||||
|
(void))))]
|
||||||
[else
|
[else
|
||||||
(raise-syntax-error #f "Expected module path" stx)]))
|
(raise-syntax-error #f "Expected module path" stx)]))
|
||||||
|
|
||||||
|
|
|
@ -12,7 +12,7 @@
|
||||||
[follow-redirection (path? . -> . path?)]
|
[follow-redirection (path? . -> . path?)]
|
||||||
[collect-redirections-to (path? . -> . (listof path?))]
|
[collect-redirections-to (path? . -> . (listof path?))]
|
||||||
|
|
||||||
[lookup-module-requires (path? . -> . (listof module-path?))])
|
[lookup-module-requires (path? . -> . (listof path?))])
|
||||||
|
|
||||||
(define-runtime-path record.rkt "record.rkt")
|
(define-runtime-path record.rkt "record.rkt")
|
||||||
(define ns (make-base-empty-namespace))
|
(define ns (make-base-empty-namespace))
|
||||||
|
|
|
@ -46,7 +46,8 @@
|
||||||
[(SexpSource? a-source)
|
[(SexpSource? a-source)
|
||||||
"<SexpSource>"]
|
"<SexpSource>"]
|
||||||
[(ModuleSource? a-source)
|
[(ModuleSource? a-source)
|
||||||
"<ModuleSource>"]))
|
(format "<ModuleSource ~a>"
|
||||||
|
(ModuleSource-path a-source))]))
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue
Block a user