Skip to content
This repository has been archived by the owner on Aug 3, 2024. It is now read-only.

Kotlin support #453

Open
artyommironov opened this issue Feb 17, 2016 · 5 comments · May be fixed by #532
Open

Kotlin support #453

artyommironov opened this issue Feb 17, 2016 · 5 comments · May be fixed by #532

Comments

@artyommironov
Copy link

Kotlin 1.0 is out. It has plugin for Eclipse with code completion, correction etc. But doesn't work in eclim.
http://kotlinlang.org/

@jreiter
Copy link

jreiter commented Jul 24, 2017

@ervandew do you have any plans to implement kotlin support? If you haven't started on this already, I might be willing to take a stab at it if you can point me in the right direction.

@yveszoundi
Copy link
Contributor

@jreiter , may I suggest the following initial steps?

A) Look at how language support for Groovy is done
I implement initial support for groovy a while back and got help from @ervandew to polish it so that it could make it into eclim. What do you think about looking at that small implementation?

B) Check how to implement features subsets
The natural step after that would be looking at the eclipse support for Kotlin

Project support
https://github.com/JetBrains/kotlin-eclipse/blob/c57c30c4096e01a5fe9ab585e77baa56e2921dee/kotlin-eclipse-core/src/org/jetbrains/kotlin/core/KotlinClasspathContainer.kt

Code completion
(https://github.com/JetBrains/kotlin-eclipse/blob/c57c30c4096e01a5fe9ab585e77baa56e2921dee/kotlin-eclipse-ui-test/src/org/jetbrains/kotlin/ui/tests/editors/completion/handlers/KotlinCompletionHandlerInsertTestCase.java).

@jreiter
Copy link

jreiter commented Aug 2, 2017

@yveszoundi, thanks! I'll take a look at the groovy implementation and the eclipse Kotlin support. After spending a little more time looking into this, I'm wondering if Eclipse is really the best way to get good Kotlin support in vim though. I wonder if investing in something like https://github.com/vhakulinen/neovim-intellij-complete will be more worthwhile for Kotlin. Or maybe even adding IntelliJ support for eclim?

I'll spend some time looking into some of these options.

@yveszoundi
Copy link
Contributor

yveszoundi commented Aug 7, 2017

@jreiter, I looked at it, very briefly, towards potential emacs integration.

Maybe you can start from my fresh github fork that adds basic Kotlin support ("potentially" completion, source synchronization, project support).

This is untested, quick and very dirty:

  • No unit tests
  • No vim integration (I don't really use vim), minimal emacs integration for code completion within existing helloworld project is shown below (kotlin-mode + emacs-eclim).
  • No compliance to eclim formatting standards (2 spaces, brackets, etc.)
  • etc.

eclim_basic_kotlin_support

I looked quickly at groovy support that I worked on before, as well as the source code for Kotlin Eclipse main features.

@yveszoundi
Copy link
Contributor

yveszoundi commented Aug 7, 2017

I picked Java over Kotlin for the implementation because of the build infrastructure (Gant).
It appears that the Eclipse Kotlin plugin doesn't ship with ant taks for invoking the Kotlin compiler.

That gave me the opportunity to write some Kotlin code for the first time. I played around with a Kotlin implementation(bootstrap jars from local installation) before java rewrite. It's definitely more fun that writing Java, plus it's easy to write code without reading tutorials or the manual :-)

@yveszoundi yveszoundi linked a pull request Aug 10, 2017 that will close this issue
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants