Kotlin / kotlin-koans

Kotlin workshop
MIT License
2.6k stars 1.41k forks source link

no "kotlinc" documentation for including "util" #47

Closed Patterner closed 8 years ago

Patterner commented 8 years ago

I tried to compile kotlin-koans/src/i_introduction/_0_Hello_World/HelloWorld.kt with kotlinc HelloWorld.kt -include-runtime -d HelloWorld.jar but it fails: HelloWorld.kt:3:8: error: unresolved reference: util import util.TODO ^

I googled for an hour, read the documentation but I couldn't find out how to do that properly.

svtk commented 8 years ago

Hi Patterner! This function is declared in the kotlinUtil.kt file in the same project. That means you have to compile the whole project, not just one file.

A convenient way to work with koans is through IDE (Intellij Idea, for example). In this case all the compilation goes automatically. You can check the online version http://try.kotlinlang.org/koans (the tasks are almost the same) as well.

Patterner commented 8 years ago

that was disappointing