Skip to content
Discussion options

You must be logged in to vote

Hey @we-wake-act21,

when building a language with imports, the way to go is to create a dedicated global scope, see our own grammar language as an example. Once you have explicit imports available, implicit imports are just an extension of this mechanism. In addition to the explicit imports, you would find which documents in your workspace/stdlib are implicitly imported, and add the exported elements of these documents to the current global scope.

Replies: 1 comment

Comment options

You must be logged in to vote
0 replies
Answer selected by msujew
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants