bob
02/08/2017, 10:15 AMlistOf( 1, "2", 3 )
.filter{ it is String }
.first()
After the filter I know that the values passing through are strings. I don't want to map them as well.
The same goes for Rx as well but afaik they don't have smart cast at all.
(Wrote a small piece on it here as well https://medium.com/@cc14ff7d5eab/13deeb88cc4f )