https://kotlinlang.org logo
m

mzgreen

04/09/2018, 8:16 AM
Aliases in Swift have a really cool property, you can do:
Copy code
interface A
interface B

class Foo: A, B

typealias AB = A & B

// and then for example:
val foo = Foo()

val isFooAB = foo is AB
I wish Kotlin had it too.