diff --git a/main-base.rkt b/main-base.rkt index ecd5a23..50188ba 100644 --- a/main-base.rkt +++ b/main-base.rkt @@ -45,10 +45,11 @@ (module inner pollen/doclang-raw DOC-RAW ; positional arg for doclang-raw that sets name of export. (require pollen/top pollen/world) - (provide #%top (all-defined-out) (all-from-out pollen/world)) + (require (submod ".." META-MOD)) + (provide (all-defined-out) #%top (all-from-out pollen/world (submod ".." META-MOD))) EXPR-WITHOUT-METAS (... ...)) - (require 'inner 'META-MOD) + (require 'inner) (define DOC (let* ([parser-mode-undefined? (procedure? inner:parser-mode)] ; if undefined, #%top makes it a procedure [parser-mode (if parser-mode-undefined? PARSER-MODE-ARG inner:parser-mode)] diff --git a/test/test-meta.rkt b/test/test-meta.rkt new file mode 100644 index 0000000..81fc633 --- /dev/null +++ b/test/test-meta.rkt @@ -0,0 +1,10 @@ +#lang racket + +;; check that a `define-meta` is immediately available +(module metatest pollen + (define-meta key "value") + (define val (hash-ref metas 'key)) + (provide val)) + +(require rackunit 'metatest) +(check-equal? val "value") \ No newline at end of file