mirror of
https://github.com/enso-org/enso.git
synced 2024-11-24 08:41:40 +03:00
d463a43633
Added a separate pass, `FullyQualifiedNames`, that partially resolves fully qualified names. The pass only resolves the library part of the name and replaces it with a reference to the `Main` module. There are 2 scenarios that could be potentially: 1) the code uses a fully qualified name to a component that has been parsed/compiled 2) the code uses a fully qualified name to a component that has **not** be imported For the former case, it is sufficient to just check `PackageRepository` for the presence of the library name. In the latter we have to ensure that the library has been already parsed and all its imports are resolved. That would require the reference to `Compiler` in the `FullyQualifiedNames` pass, which could then trigger a full compilation for missing library. Since it has some undesired consequences (tracking of dependencies becomes rather complex) we decided to exclude that scenario until it is really needed. # Important Notes With this change, one can use a fully qualified name directly. e.g. ``` import Standard.Base main = Standard.Base.IO.println "Hello world!" ``` |
||
---|---|---|
.. | ||
language-server | ||
launcher/src | ||
polyglot-api/src | ||
runner | ||
runtime | ||
runtime-instrument-id-execution/src/main/java/org/enso/interpreter/instrument | ||
runtime-instrument-repl-debugger/src/main/java/org/enso/interpreter/instrument | ||
runtime-instrument-runtime-server/src/main/java/org/enso/interpreter/instrument | ||
runtime-language-epb/src/main/java/org/enso/interpreter/epb | ||
runtime-with-instruments/src/test | ||
runtime-with-polyglot/src/test | ||
README.md |
The Enso Engine
The Enso engine is the codebase responsible for compiling and executing Enso code, as well as providing language server functionality to users of the language. It is subdivided into two major components:
- Language Server: The Enso language service.
- Polyglot API: The truffle-boundary safe API for communication between the language server and the runtime.
- Runner: The command-line interface for Enso.
- Runtime: The compiler and interpreter for Enso.