https://kotlinlang.org logo
#random
Title
c

Caleb Allen

05/07/2018, 10:26 PM
This does not compile, and I realized that a method with the signature
handle(response: Response)
with a
when
body would achieve the same effect, but I wonder if something like this could work. Then instead of me needing to call
handle
in each
when
branch (therefore resolving the type), the compiler would resolve the type for me.