4 ms·
May I ask why do you think kotlin is best designed?
by bulldoa 6y ago
May I ask why do you think kotlin is best designed?
- djanogo 6y agoI think kotlin is ugly hack, if you take away the superficial syntax (?) it will start showing ugly side. I think it only gotten popular because of Googles push due to Oracle Java lawsuit.
- monocasa 6y agoI don't think Kotlin is being pushed because of the Oracle lawsuit. Most of Oracle's complaints were at the VM and standard library level, which Kotlin doesn't help with.
- eggsnbacon1 6y agoKotlin allows Google to hang out in Java 8 forever. If they want new features they can just add them at the Kotlin layer. Insulates them from OpenJDK and any changes Oracle wants to make. All great opportunities to fragment the Java ecosystem
- monocasa 6y agoOpenJDK was always fine for them to pull in, being GPLed. They got in trouble because they based their class library on Apache Harmony originally, and Sun pulled the TCK rug out from under Harmony.
- t-writescode 6y agoKotlin is written by JetBrains.
- searchableguy 6y agoCan you elaborate on ugly side?
- deleted 6y ago[deleted]
- The_Colonel 6y agoIt has the benefit of 15 years more hindsight. As an example, during this time the development community figured out that using immutability as the default brings benefits. Kotlin is designed with this in mind, but C# isn't - e.g. C# has this cool feature for object initialization which is so handy and all developers use it. Except for - it doesn't work with immutable classes (the ones with readonly fields). As an effect developers dislike to use immutable classes since it's not ergonomic in C# and instead use standard POCO. Another example is that C# still in this age does not support readonly parameters and local variables (which even Java and JavaScript (!) support). In Kotlin "readonly" local variables is the idiomatic code practice which doesn't make code any more verbose. And in the case they decide to add it to C#, it will have to be at the cost of verbosity (similarly to how Java does it) because of backwards compatibility.
- belinder 6y ago> Except for - it doesn't work with immutable classes (the ones with readonly fields). Well good thing they're adding that in C# 9 then
- The_Colonel 6y agoOh, cool, I didn't notice that! Still, they are playing catch-up here.
- illvm 6y agoI mean... if you go that route then I would say Kotlin isn't really ready to be used as a production language in most places due to the severe lack of tooling, especially when it comes to things like static analysis. Sure ktlint is there, but the rules library is lacking. So from that perspective, Kotlin is playing catch-up.
- The_Colonel 6y agoDiscussion was about the design of the language only.