Replies: 2 comments 1 reply
-
Steps.
|
Beta Was this translation helpful? Give feedback.
1 reply
-
Having Ruby like modules is a big mess. Introducing a lot of types and processing to runtime. Experimenting with runtime modules costed me almost 2 weeks. Module name resolution and exports will be part of multi-pass compilation. Clean and no runtime changes.
|
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
here are different kinds of Modules on different languages.
So the languages have 3 approaches
What is the matter? By making, modules part of the runtime, one is able to disable static type checking totally because type checking depends on modules.
Currently I started modules as runtime objects. But it might easily disable future type checking, by having this or that feature.
Modules resolved before runtime
Pros:
Cons:
In the name of simplicity, I am tending to preresolving modules with a cost of implementing a separate module info export.
Processing modules at run-time is bringing the risk of making static type checking impossible.
Summary:
I decided to demolish existing Modules. And parser will just delegate Math.sth as a single identifier for the existing mega switch statement. The reason for that is we are about to demolish any possibility of static type checking by allowing modules to be modified during runtime.
Steps:
Beta Was this translation helpful? Give feedback.
All reactions