Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Kotlin stub/placeholder function for unimplemented code

Tags:

kotlin

Scala's Predef has a bunch of shorthand functions including one for unimplemented code, namely ???. Does Kotlin have anything similar rather than having to resort to the longhand

throw Error("Code not yet implemented")

1 Answers

Since Kotlin 1.0, you can use the TODO function from the Kotlin standard library, which takes an optional message.

like image 182
Alexander Udalov Avatar answered Oct 25 '25 11:10

Alexander Udalov



Donate For Us

If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!