It’d be nice if smart casts worked with `filter`. ...
# announcements
b
It’d be nice if smart casts worked with
filter
. I’ve encountered this type of code on several occasions
Copy code
val myList: List<SomeType?>
myList.filter { it is SomeType }.map { it as SomeType }.doSomething()