https://kotlinlang.org logo
#getting-started
Title
# getting-started
r

rustyrazorblade

02/03/2023, 7:43 PM
Hey folks - is it possible to have a generic function with multiple constraints?
c

Casey Brooks

02/03/2023, 7:50 PM
Yes, you can use a
where
clause to require the generic parameter to satisfy multiple constraints https://kotlinlang.org/docs/generics.html#upper-bounds
r

rustyrazorblade

02/03/2023, 7:55 PM
🙏
k

Kevin Del Castillo

02/03/2023, 9:28 PM
Reminds me a lot of Rust, cool, we're just missing the ability to implement interfaces after class definition 🤕
r

rustyrazorblade

02/03/2023, 10:00 PM
speaking of Rust, I’ve barely programmed in over a year… the mind rot is real
5 Views