Inspectopedia Help

Redundant enum constructor invocation

Reports redundant constructor invocation on an enum entry.

Example:

enum class Baz(i: Int = 0) { A(1), B(), C(), }

After the quick-fix is applied:

enum class Baz(i: Int = 0) { A(1), B, C, }

Inspection Details

Available in:

IntelliJ IDEA 2023.3, Qodana for JVM 2023.3

Plugin:

Kotlin, @snapshot@

Last modified: 13 July 2023