mirror of
https://github.com/enso-org/enso.git
synced 2024-11-27 18:12:31 +03:00
3a42d0ce76
Remove the magical code generation of `enso_project` method from codegen phase and reimplement it as a proper builtin method. The old behavior of `enso_project` was special, and violated the language semantics (regarding the `self` argument): - It was implicitly declared in every module, so it could be called without a self argument. - It can be called with explicit module as self argument, e.g. `Base.enso_project`, or `Visualizations.enso_project`. Let's avoid implicit methods on modules and let's be explicit. Let's reimplement the `enso_project` as a builtin method. To comply with the language semantics, we will have to change the signature a bit: - `enso_project` is a static method in the `Standard.Base.Meta.Enso_Project` module. - It takes an optional `project` argument (instead of taking it as an explicit self argument). Having the `enso_project` defined as a (shadowed) builtin method, we will automatically have suggestions created for it. # Important Notes - Truffle nodes are no longer generated in codegen phase for the `enso_project` method. It is a standard builtin now. - The minimal import to use `enso_project` is now `from Standard.Base.Meta.Enso_Project import enso_project`. - Tested implicitly by `org.enso.compiler.ExecCompilerTest#testInvalidEnsoProjectRef`. |
||
---|---|---|
.. | ||
interpreter-dsl-test/src/test/java/org/enso/interpreter/dsl/test | ||
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.