https://kotlinlang.org logo
#announcements
Title
# announcements
l

ltongues

02/28/2018, 5:46 PM
Why would you want to create a secondary constructor with optional parameter that just delegates to primary constructor with the same non-optional parameter? Case in point: https://github.com/Jetbrains/kotlin/commit/8d5e69b06cb9e6a33f4d65a099d02d6a96b35c61#diff-6f01e20fe41ed86ccfc251b5bb7d2f74R52
Copy code
class KotlinInlineValHandler(private val withPrompt: Boolean) : InlineActionHandler() {

    constructor(): this(withPrompt = true)