Comparison to Scala

Comparison to Scala

The main goal of the Kotlin team is to create a pragmatic and productive programming language, rather than to advance the state of the art in programming language research. Taking this into account, if you are happy with Scala, you most likely do not need Kotlin.

What Scala has that Kotlin does not

  • Implicit conversions, parameters, etc
    • In Scala, sometimes it's very hard to tell what's happening in your code without using a debugger, because too many implicits get into the picture
    • To enrich your types with functions in Kotlin use Extension functions.
  • Overridable type members
  • Path-dependent types
  • Macros
  • Existential types
  • Complicated logic for initialization of traits
  • Custom symbolic operations
  • Structural types
  • Value types
  • Yield operator and actors
  • Parallel collections
    • Kotlin supports Java 8 streams, which provide similar functionality

What Kotlin has that Scala does not

© 2010–2017 JetBrains s.r.o.
Licensed under the Apache License, Version 2.0.
https://kotlinlang.org/docs/reference/comparison-to-scala.html

在线笔记
App下载
App下载

扫描二维码

下载编程狮App

公众号
微信公众号

编程狮公众号

意见反馈
返回顶部