Smart casting is a great feature, and it seems to work with many standard control-flow mechanisms. But something like this does not work:
var foo: Any? = null
require (foo is Int)
foo++
Are there plans to support this feature?
Smart casting is a great feature, and it seems to work with many standard control-flow mechanisms. But something like this does not work:
var foo: Any? = null
require (foo is Int)
foo++
Are there plans to support this feature?
It does work since version 1.3
fun main() {
//sampleStart
var foo: Any? = null
require(foo is Int)
foo++
//sampleEnd
}