Reorganise repo for further development (#308)

This commit is contained in:
Ara Adkins 2019-11-08 17:32:48 +00:00 committed by GitHub
parent 460205c2b9
commit bfe81a731f
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
229 changed files with 84 additions and 23 deletions

View File

@ -15,9 +15,8 @@ results and visually profile the performance in real-time.
Visit [The Enso Website](http://www.luna-lang.org) to learn more!
This repository contains the Enso interpreter and runtime, as well as its
command-line interface. For the full (visual) Enso Studio, please take a look at
[Enso Studio](https://github.com/luna/luna-studio).
This repository contains both the [Enso Engine](engine/) (its compiler,
interpreter, runtime, and language server), and its cloud-ready [IDE](ide/).
## Contributing to Enso
If you are interested in contributing to the development of Enso, please read

View File

@ -45,15 +45,15 @@ jobs:
displayName: Benchmark the Parser
continueOnError: true
- script: |
sbt -no-colors interpreter/Benchmark/compile
displayName: Check Interpreter Benchmarks Compile
sbt -no-colors runtime/Benchmark/compile
displayName: Check Runtime Benchmarks Compile
continueOnError: true
- task: PublishTestResults@2
inputs:
testResultsFormat: 'JUnit'
testResultsFiles: '**/TEST-*.xml'
- script: |
sbt interpreter/assembly
sbt runtime/assembly
displayName: Build the Uberjar
continueOnError: true
- task: CopyFiles@2
@ -95,8 +95,8 @@ jobs:
displayName: Benchmark the Parser
continueOnError: true
- script: |
sbt -no-colors interpreter/Benchmark/compile
displayName: Check Interpreter Benchmarks Compile
sbt -no-colors runtime/Benchmark/compile
displayName: Check Runtime Benchmarks Compile
continueOnError: true
- task: PublishTestResults@2
inputs:
@ -134,8 +134,8 @@ jobs:
displayName: Benchmark the Parser
continueOnError: true
- script: |
sbt interpreter/Benchmark/compile
displayName: Check Interpreter Benchmarks Compile
sbt runtime/Benchmark/compile
displayName: Check Runtime Benchmarks Compile
continueOnError: true
- task: PublishTestResults@2
inputs:

View File

@ -89,7 +89,16 @@ lazy val buildNativeImage =
lazy val enso = (project in file("."))
.settings(version := "0.1")
.aggregate(syntax, pkg, interpreter)
.aggregate(
syntax,
pkg,
runtime,
flexer,
unused,
syntax_definition,
file_manager,
project_manager
)
.settings(Global / concurrentRestrictions += Tags.exclusive(Exclusive))
////////////////////////////
@ -144,14 +153,14 @@ val jmh = Seq(
//// Sub-Projects ////
//////////////////////
lazy val logger = (project in file("lib/logger"))
lazy val logger = (project in file("common/scala/logger"))
.dependsOn(unused)
.settings(
version := "0.1",
libraryDependencies ++= scala_compiler
)
lazy val flexer = (project in file("lib/flexer"))
lazy val flexer = (project in file("common/scala/flexer"))
.dependsOn(logger)
.settings(
version := "0.1",
@ -162,10 +171,10 @@ lazy val flexer = (project in file("lib/flexer"))
)
)
lazy val unused = (project in file("lib/unused"))
lazy val unused = (project in file("common/scala/unused"))
.settings(version := "0.1", scalacOptions += "-nowarn")
lazy val syntax_definition = (project in file("Syntax/definition"))
lazy val syntax_definition = (project in file("common/scala/syntax/definition"))
.dependsOn(logger, flexer)
.settings(
libraryDependencies ++= monocle ++ cats ++ scala_compiler ++ Seq(
@ -173,7 +182,7 @@ lazy val syntax_definition = (project in file("Syntax/definition"))
)
)
lazy val syntax = (project in file("Syntax/specialization"))
lazy val syntax = (project in file("common/scala/syntax/specialization"))
.dependsOn(logger, flexer, syntax_definition)
.configs(Test)
.configs(Benchmark)
@ -204,7 +213,7 @@ lazy val syntax = (project in file("Syntax/specialization"))
.value
)
lazy val pkg = (project in file("Pkg"))
lazy val pkg = (project in file("common/scala/pkg"))
.settings(
mainClass in (Compile, run) := Some("org.enso.pkg.Main"),
version := "0.1",
@ -222,7 +231,7 @@ val truffleRunOptionsSettings = Seq(
javaOptions ++= truffleRunOptions
)
lazy val interpreter = (project in file("Interpreter"))
lazy val runtime = (project in file("engine/runtime"))
.settings(
mainClass in (Compile, run) := Some("org.enso.interpreter.Main"),
mainClass in assembly := (Compile / run / mainClass).value,
@ -308,7 +317,7 @@ lazy val interpreter = (project in file("Interpreter"))
.dependsOn(pkg)
.dependsOn(syntax)
lazy val fileManager = (project in file("FileManager"))
lazy val file_manager = (project in file("common/scala/file-manager"))
.settings(
(Compile / mainClass) := Some("org.enso.filemanager.FileManager")
)
@ -323,7 +332,7 @@ lazy val fileManager = (project in file("FileManager"))
libraryDependencies += "io.methvin" % "directory-watcher" % "0.9.6"
)
lazy val projectManager = (project in file("ProjectManager"))
lazy val project_manager = (project in file("common/scala/project-manager"))
.settings(
(Compile / mainClass) := Some("org.enso.projectmanager.Server")
)

View File

@ -70,7 +70,7 @@ object ParserBenchmark extends Bench.OfflineRegressionReport {
)
val filename = "Syntax/specialization/target/bench-input.txt"
val filename = "common/scala/syntax/specialization/target/bench-input.txt"
if (!new File(filename).exists()) {
val file = new PrintWriter(new File(filename))

47
engine/README.md Normal file
View File

@ -0,0 +1,47 @@
# 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:
- [Runtime](#runtime)
- [Language Server](#language-server)
## Runtime
The Enso [runtime](/runtime) is responsible for the actual execution of Enso
code. This means that it encompasses the following functionality:
- **Parsing:** Taking Enso code as input and generating an AST that maintains a
sophisticated set of information about the input.
- **Desugaring:** Reducing the user-facing Enso code into a simplified language
known as `Core`.
- **Type Inference:** Inferring the types of bindings in the user's code.
- **Type Checking:** Checking that the inferred and provided types for bindings
match up across the codebase.
- **Optimisation:** Static optimisation processes to improve the performance of
the user's program.
- **Code Execution:** Actually running the Enso code.
- **Introspection Hooks:** Providing hooks into the running code to allow the
language server to inspect information about the code as it runs.
## Language Server
The Enso Language Server is responsibile for providing a remote-communication
protocol for the runtime, exposing many of its features to the users. In
addition it provides the backing service for much of the IDE functionality
associated with the language. It encompasses the following functionality:
- **Introspection Services:** Giving clients the ability to observe information
about their running code including values, types, profiling information, and
debugging.
- **Code Execution:** The ability for clients to execute arbitrary Enso code in
arbitrary scopes. This can be used in conjunction with the above to provide
a REPL with an integrated debugger.
- **Code Completion:** Sophisticated completion functionality that refines
suggestions intelligently based on context.
- **Node Management:** Tracking and providing the language server's internal
node representation of the Enso program.
- **Code Analysis:** Analysis functionality for Enso code (e.g. find usages,
jump-to-definition, and so on).
- **Refactoring:** Refactoring functionality for Enso code (e.g. rename, move,
extract, and so on).
- **Type Interactions:** Features for type-driven-development that allow users
to interact with the types of their programs.

View File

@ -1,4 +1,4 @@
# Enso Interpreter
# Enso Compiler and Interpreter
### Truffle Nodes creation convention
@ -15,4 +15,4 @@ The only exception are nodes that are never expected to be a part of an AST
should be implemented instead.
This convention should be implemented for every node throughout this codebase
if you see one not obeying it please fix it.
if you see one not obeying it please fix it.

Some files were not shown because too many files have changed in this diff Show More