drop deprecated @platformName and @platformStatic annotations
This commit is contained in:
+1
-3
@@ -1,8 +1,6 @@
|
||||
package ppp
|
||||
|
||||
import kotlin.platform.platformStatic
|
||||
|
||||
public object Dependency {
|
||||
@platformStatic
|
||||
@JvmStatic
|
||||
public val FIELD: Int = 1
|
||||
}
|
||||
@@ -1,14 +1,12 @@
|
||||
// PSI_ELEMENT: org.jetbrains.kotlin.psi.KtObjectDeclaration
|
||||
// OPTIONS: usages
|
||||
|
||||
import kotlin.platform.platformStatic
|
||||
|
||||
class Foo {
|
||||
companion <caret>object {
|
||||
fun f() {
|
||||
}
|
||||
|
||||
@platformStatic fun s() {
|
||||
@JvmStatic fun s() {
|
||||
}
|
||||
|
||||
val CONST = 42
|
||||
|
||||
@@ -1,7 +1,5 @@
|
||||
package companionObjectUsedInJava
|
||||
|
||||
import kotlin.platform.platformStatic
|
||||
|
||||
class A {
|
||||
companion object {
|
||||
val CONST = 42
|
||||
@@ -10,7 +8,7 @@ class A {
|
||||
|
||||
class B {
|
||||
companion object {
|
||||
platformStatic fun foo() {
|
||||
@JvmStatic fun foo() {
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -23,7 +21,7 @@ class C {
|
||||
|
||||
class D {
|
||||
companion object Named {
|
||||
platformStatic fun foo() {
|
||||
@JvmStatic fun foo() {
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
+1
-1
@@ -2,7 +2,7 @@ package companionObjectWithStatics
|
||||
|
||||
class Foo {
|
||||
companion object {
|
||||
platformStatic fun foo() {
|
||||
@JvmStatic fun foo() {
|
||||
}
|
||||
|
||||
val CONST = 111
|
||||
|
||||
@@ -2,10 +2,8 @@ package entryPoint
|
||||
|
||||
// WITH_RUNTIME
|
||||
|
||||
import kotlin.platform.platformStatic
|
||||
|
||||
object EntryPoint {
|
||||
@platformStatic public fun main(args: Array<String>) {
|
||||
@JvmStatic public fun main(args: Array<String>) {
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
@@ -1,10 +1,8 @@
|
||||
// FULL_JDK
|
||||
|
||||
import kotlin.platform.platformStatic
|
||||
|
||||
class Klass : java.io.Serializable {
|
||||
companion object {
|
||||
private platformStatic val serialVersionUID: Long = 239
|
||||
private @JvmStatic val serialVersionUID: Long = 239
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -3,7 +3,7 @@ class Foo {
|
||||
fun f() {
|
||||
}
|
||||
|
||||
platformStatic fun s() {
|
||||
@JvmStatic fun s() {
|
||||
}
|
||||
|
||||
val CONST = 42
|
||||
|
||||
@@ -3,7 +3,7 @@ class Foo {
|
||||
fun f() {
|
||||
}
|
||||
|
||||
platformStatic fun s() {
|
||||
@JvmStatic fun s() {
|
||||
}
|
||||
|
||||
val CONST = 42
|
||||
|
||||
+1
-1
@@ -3,7 +3,7 @@ class Foo {
|
||||
fun f() {
|
||||
}
|
||||
|
||||
platformStatic fun s() {
|
||||
@JvmStatic fun s() {
|
||||
}
|
||||
|
||||
val CONST = 42
|
||||
|
||||
+1
-1
@@ -3,7 +3,7 @@ class Foo {
|
||||
fun f() {
|
||||
}
|
||||
|
||||
platformStatic fun s() {
|
||||
@JvmStatic fun s() {
|
||||
}
|
||||
|
||||
val CONST = 42
|
||||
|
||||
+1
-1
@@ -3,7 +3,7 @@ class Foo {
|
||||
fun f() {
|
||||
}
|
||||
|
||||
platformStatic fun s() {
|
||||
@JvmStatic fun s() {
|
||||
}
|
||||
|
||||
val CONST = 42
|
||||
|
||||
Vendored
+1
-1
@@ -3,7 +3,7 @@ class Foo {
|
||||
fun f() {
|
||||
}
|
||||
|
||||
platformStatic fun s() {
|
||||
@JvmStatic fun s() {
|
||||
}
|
||||
|
||||
val CONST = 42
|
||||
|
||||
+1
-3
@@ -1,7 +1,5 @@
|
||||
package k
|
||||
|
||||
import kotlin.platform.platformStatic
|
||||
|
||||
public class Class() {
|
||||
public val prop: Int = 0
|
||||
fun function() = 1
|
||||
@@ -32,7 +30,7 @@ public interface StaticFieldInClassObjectInTrait {
|
||||
}
|
||||
|
||||
object PlatformStaticFun {
|
||||
platformStatic
|
||||
@JvmStatic
|
||||
fun test() {
|
||||
}
|
||||
}
|
||||
|
||||
+5
-7
@@ -1,11 +1,9 @@
|
||||
package q
|
||||
|
||||
import kotlin.platform.platformStatic
|
||||
|
||||
// RUN: q.Foo
|
||||
object Foo {
|
||||
// RUN: q.Foo
|
||||
@platformStatic fun main(s: Array<String>) {
|
||||
@JvmStatic fun main(s: Array<String>) {
|
||||
println("Foo")
|
||||
}
|
||||
|
||||
@@ -13,7 +11,7 @@ object Foo {
|
||||
class InnerFoo {
|
||||
companion object {
|
||||
// RUN: q.Foo.InnerFoo
|
||||
@platformStatic fun main(s: Array<String>) {
|
||||
@JvmStatic fun main(s: Array<String>) {
|
||||
println("InnerFoo")
|
||||
}
|
||||
}
|
||||
@@ -22,7 +20,7 @@ object Foo {
|
||||
// RUN: q.Foo
|
||||
class InnerFoo2 {
|
||||
// RUN: q.Foo
|
||||
@platformStatic fun main(s: Array<String>) {
|
||||
@JvmStatic fun main(s: Array<String>) {
|
||||
println("InnerFoo")
|
||||
}
|
||||
}
|
||||
@@ -40,7 +38,7 @@ object Foo2 {
|
||||
class Bar {
|
||||
companion object {
|
||||
// RUN: q.Bar
|
||||
@platformStatic fun main(s: Array<String>) {
|
||||
@JvmStatic fun main(s: Array<String>) {
|
||||
println("Bar")
|
||||
}
|
||||
}
|
||||
@@ -59,7 +57,7 @@ class Bar2 {
|
||||
// RUN: q.TestKt
|
||||
class Baz {
|
||||
// RUN: q.TestKt
|
||||
platformStatic fun main(s: Array<String>) {
|
||||
@JvmStatic fun main(s: Array<String>) {
|
||||
println("Baz")
|
||||
}
|
||||
}
|
||||
|
||||
@@ -1,11 +1,8 @@
|
||||
package companions
|
||||
|
||||
import kotlin.platform.platformName
|
||||
import kotlin.platform.platformStatic
|
||||
|
||||
class A {
|
||||
companion object {
|
||||
@platformStatic
|
||||
@JvmStatic
|
||||
fun main(args: Array<String>) {
|
||||
// yes
|
||||
}
|
||||
@@ -22,8 +19,8 @@ class B {
|
||||
|
||||
class C {
|
||||
companion object {
|
||||
@platformStatic
|
||||
@platformName("main0")
|
||||
@JvmStatic
|
||||
@JvmName("main0")
|
||||
fun main(args: Array<String>) { // no
|
||||
}
|
||||
}
|
||||
@@ -31,8 +28,8 @@ class C {
|
||||
|
||||
class D {
|
||||
companion object {
|
||||
@platformStatic
|
||||
@platformName("main")
|
||||
@JvmStatic
|
||||
@JvmName("main")
|
||||
fun badName(args: Array<String>) { // yes
|
||||
}
|
||||
}
|
||||
|
||||
@@ -1,8 +1,6 @@
|
||||
package pkg2
|
||||
|
||||
import kotlin.platform.platformName
|
||||
|
||||
@platformName("aa")
|
||||
@JvmName("aa")
|
||||
fun main(args: Array<String>) {
|
||||
// no
|
||||
}
|
||||
|
||||
@@ -1,8 +1,6 @@
|
||||
package pkg3
|
||||
|
||||
import kotlin.platform.platformName
|
||||
|
||||
@platformName("main")
|
||||
@JvmName("main")
|
||||
fun aaa(args: Array<String>) {
|
||||
// yes
|
||||
}
|
||||
|
||||
+1
-3
@@ -1,8 +1,6 @@
|
||||
package renameTest
|
||||
|
||||
import kotlin.platform.platformStatic
|
||||
|
||||
object Foo {
|
||||
@platformStatic fun main(args: Array<String>) {
|
||||
@JvmStatic fun main(args: Array<String>) {
|
||||
}
|
||||
}
|
||||
|
||||
@@ -1,8 +1,6 @@
|
||||
package renameTest
|
||||
|
||||
import kotlin.platform.platformStatic
|
||||
|
||||
object Foo {
|
||||
@platformStatic fun main(args: Array<String>) {
|
||||
@JvmStatic fun main(args: Array<String>) {
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user