it will be available in a future versions of Kotlin. There is internal Kotlin API called Contracts, but it’s not ready yet
It will help compiler to understand contact of such functions
s
spierce7
03/11/2018, 6:28 PM
I'm so impressed with the tooling and improvements you guys are making to kotlin. What a great future feature! I look forward to it.