Hacker Newsnew | past | comments | ask | show | jobs | submitlogin

Looks similar to Haxe, in that they're targeting interoperability. But with less platform support.

I personally have yet to use Haxe, but the people I know who use it love it. I'm keeping it in mind for a good use case! Such as sharing application logic across applications, though in practice last time I did that things got very messy, it was easier just to duplicate application logic across applications. Kotlin/Haxe would be great for cross platform libraries though.

Both Kotlin and Haxe do have GADT, which is a feature I'm finding harder to live without :D Also Kotlin appears to have record types!



Kotlin seems to be a good deal simpler than Haxe. Haxe seems to be closer to Scala in terms of complexity, while Kotlin really just boils down to a few extra features relative to Java 8.

As far as I know, Kotlin does not have algebreic data types. It does have the nullable type `T?` which is basically Option or Maybe, but you can't define your own.

Haxe's enums are algebreic types, but I don't think it has full support for generalized algebreic data types.


Haxe has GADTs, and I think they're great. http://en.wikipedia.org/wiki/Haxe#Type_system


Duplicating app logic is not so bad if it's just a simple one off, and you know the languages well.

Haxe is pretty awesome once you start working a server/client app from a single code base. You save so much mental energy not having to do context switching on a language, and you're not afraid to make drastic changes to logic or data structures because you're making both changes at the same time.




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: