https://kotlinlang.org logo
#announcements
Title
# announcements
o

orangy

09/18/2017, 10:10 PM
This concept allows evolving language easier in the future. You can’t normally add another hard keyword without breaking some code. E.g. we added
suspend
in 1.1 without breaking any code that might be using
val suspend = shouldSuspendUser()
💯 12
t

trubesv

09/18/2017, 10:22 PM
Great thinking, kind of why I like Kotlin more and more each day 🙂 My reaction was about the dirty snippet (no offense intended @kevinmost):
Copy code
public val private: public = public()
class public {
}
k

kevinmost

09/18/2017, 10:39 PM
that snippet is terrible and I hope people try to avoid abusing soft keywords like this, haha
t

trubesv

09/18/2017, 10:39 PM
IntelliJ should display a "BAD PRACTICE" message
in bold red letters
flashing on screen with a strident sound
m

melston

09/18/2017, 10:44 PM
and sending email to your boss!
o

orangy

09/18/2017, 10:45 PM
Disables Kotlin plugin for 24 hours and forces you to write code in Java.
🧌 7
t

trubesv

09/18/2017, 10:46 PM
Without lambdas
a

artem_zin

09/18/2017, 11:27 PM
Actually Kotlin already has a tool to prohibit that — called Kapt (stands for Kotlin Absurd Prevention Tool) , which doesn’t escape things like
public
properly so they slip into generated
.java
files and then javac fails your build lol
😂 1
o

orangy

09/18/2017, 11:45 PM
@yan
a

artem_zin

09/18/2017, 11:59 PM
But I can’t tell from the fix commit if it helps with things like
val public: Boolean
<https://github.com/jetbrains/kotlin/commit/a98313797839b8104e79a6a75f6f779d5ef5d315>
y

yan

09/19/2017, 2:34 PM
@artem_zin Newer versions of Kotlin should simply ignore declarations with “Java-incompatible” names.
👍 1