typelead / eta

The Eta Programming Language, a dialect of Haskell on the JVM
https://eta-lang.org
BSD 3-Clause "New" or "Revised" License
2.61k stars 141 forks source link

Add support for java-sources in eta repl #959

Closed jneira closed 5 years ago

jneira commented 5 years ago

With those changes now it is possible to compile and load javaish targets (.java. class. jar) It works at repl startup and with :load (i.e. you can do :load path/to/my.(java|class|jar) on the fly)

Description

Main changes are in Eta.REPL.UI module where it is the calling code to Eta.Main.DriverPipeline to compile files and Eta.REPL.Linker to add them to repl classpath.

How Has This Been Tested?

Manually firing repls with different java source files

Types of changes

Checklist:

jneira commented 5 years ago

@rahulmutt thanks! not a perfect solution but it can work for now The hard part was reading the source files to guess where to put the code 😆 Now i know a little bit (only a little!) more of ghc flow