Remove unnecessary constructor keyword intention (KT-29143)
#KT-29143 Fixed
This commit is contained in:
committed by
Nikolay Krasko
parent
c10eadfa77
commit
185d0c6165
@@ -0,0 +1 @@
|
||||
org.jetbrains.kotlin.idea.intentions.RemoveConstructorKeywordIntention
|
||||
@@ -0,0 +1 @@
|
||||
abstract class Base <caret>constructor(val x: Int)
|
||||
@@ -0,0 +1 @@
|
||||
abstract class Base(val x: Int)
|
||||
@@ -0,0 +1,5 @@
|
||||
annotation class Ann
|
||||
|
||||
class AnnotatedParam <caret>constructor(@Ann x: Double) {
|
||||
val y = x
|
||||
}
|
||||
@@ -0,0 +1,5 @@
|
||||
annotation class Ann
|
||||
|
||||
class AnnotatedParam(@Ann x: Double) {
|
||||
val y = x
|
||||
}
|
||||
@@ -0,0 +1 @@
|
||||
annotation class Ann <caret>constructor(val i: Int)
|
||||
@@ -0,0 +1 @@
|
||||
annotation class Ann(val i: Int)
|
||||
@@ -0,0 +1,12 @@
|
||||
/**
|
||||
* An important class
|
||||
*/
|
||||
class WithComments
|
||||
/**
|
||||
* Some nasty constructor
|
||||
*/
|
||||
constructor(
|
||||
/* First parameter */
|
||||
val first: Int,<caret>
|
||||
/* Second Parameter */
|
||||
val second: Double)
|
||||
@@ -0,0 +1,11 @@
|
||||
/**
|
||||
* An important class
|
||||
*/
|
||||
class WithComments
|
||||
/**
|
||||
* Some nasty constructor
|
||||
*/(
|
||||
/* First parameter */
|
||||
val first: Int,
|
||||
/* Second Parameter */
|
||||
val second: Double)
|
||||
@@ -0,0 +1 @@
|
||||
data class Data <caret>constructor(val value: String)
|
||||
@@ -0,0 +1 @@
|
||||
data class Data(val value: String)
|
||||
@@ -0,0 +1 @@
|
||||
class InParameters constructor(val x: Int, val y: Int = 7, private <caret>val z: Int = 13)
|
||||
@@ -0,0 +1 @@
|
||||
class InParameters(val x: Int, val y: Int = 7, private val z: Int = 13)
|
||||
@@ -0,0 +1 @@
|
||||
class VarargVal <caret>constructor(vararg val param: String)
|
||||
@@ -0,0 +1 @@
|
||||
class VarargVal(vararg val param: String)
|
||||
@@ -0,0 +1 @@
|
||||
class WithProperties constructor<caret>(val x: Int, val y: Int = 7, private val z: Int = 13)
|
||||
@@ -0,0 +1 @@
|
||||
class WithProperties(val x: Int, val y: Int = 7, private val z: Int = 13)
|
||||
Reference in New Issue
Block a user