AllOpen: Do not make private members open (KT-16627)

This commit is contained in:
Yan Zhulanow
2017-03-13 19:31:42 +03:00
parent bb0a46ac17
commit 5d4cefcc30
4 changed files with 47 additions and 1 deletions

View File

@@ -0,0 +1,16 @@
annotation class AllOpen
@AllOpen
private class Test {
fun publicMethod() {}
val publicProp: String = ""
protected fun protectedMethod() {}
protected val protectedProp: String = ""
private fun privateMethod() {}
private val privateProp: String = ""
internal fun internalMethod() {}
internal val internalProp: String = ""
}

View File

@@ -0,0 +1,20 @@
@java.lang.annotation.Retention
@kotlin.Metadata
public annotation class AllOpen
@AllOpen
@kotlin.Metadata
class Test {
private final @org.jetbrains.annotations.NotNull field internalProp: java.lang.String
private final field privateProp: java.lang.String
private final @org.jetbrains.annotations.NotNull field protectedProp: java.lang.String
private final @org.jetbrains.annotations.NotNull field publicProp: java.lang.String
public method <init>(): void
public @org.jetbrains.annotations.NotNull method getInternalProp$test_module(): java.lang.String
protected @org.jetbrains.annotations.NotNull method getProtectedProp(): java.lang.String
public @org.jetbrains.annotations.NotNull method getPublicProp(): java.lang.String
public method internalMethod$test_module(): void
private final method privateMethod(): void
protected method protectedMethod(): void
public method publicMethod(): void
}