Add compiler argument -Xfriend-paths for kotlinc-jvm
#KT-21910 Fixed
This commit is contained in:
Vendored
+15
@@ -0,0 +1,15 @@
|
||||
package a
|
||||
|
||||
internal interface InternalInterface
|
||||
|
||||
public class PublicClass {
|
||||
internal fun internalMemberFun() {}
|
||||
|
||||
internal companion object {}
|
||||
}
|
||||
|
||||
internal val internalVal = ""
|
||||
|
||||
internal fun internalFun(s: String): String = s
|
||||
|
||||
internal typealias InternalTypealias = InternalInterface
|
||||
+19
@@ -0,0 +1,19 @@
|
||||
compiler/testData/compileKotlinAgainstCustomBinaries/internalFromForeignModule/source.kt:3:21: error: cannot access 'InternalInterface': it is internal in 'a'
|
||||
private fun test(i: InternalInterface): InternalTypealias {
|
||||
^
|
||||
compiler/testData/compileKotlinAgainstCustomBinaries/internalFromForeignModule/source.kt:3:41: error: cannot access 'InternalTypealias': it is internal in 'a'
|
||||
private fun test(i: InternalInterface): InternalTypealias {
|
||||
^
|
||||
compiler/testData/compileKotlinAgainstCustomBinaries/internalFromForeignModule/source.kt:4:19: error: cannot access 'internalMemberFun': it is internal in 'PublicClass'
|
||||
PublicClass().internalMemberFun()
|
||||
^
|
||||
compiler/testData/compileKotlinAgainstCustomBinaries/internalFromForeignModule/source.kt:5:17: error: cannot access 'Companion': it is internal in 'PublicClass'
|
||||
PublicClass.Companion
|
||||
^
|
||||
compiler/testData/compileKotlinAgainstCustomBinaries/internalFromForeignModule/source.kt:7:5: error: cannot access 'internalFun': it is internal in 'a'
|
||||
internalFun(internalVal)
|
||||
^
|
||||
compiler/testData/compileKotlinAgainstCustomBinaries/internalFromForeignModule/source.kt:7:17: error: cannot access 'internalVal': it is internal in 'a'
|
||||
internalFun(internalVal)
|
||||
^
|
||||
COMPILATION_ERROR
|
||||
+10
@@ -0,0 +1,10 @@
|
||||
import a.*
|
||||
|
||||
private fun test(i: InternalInterface): InternalTypealias {
|
||||
PublicClass().internalMemberFun()
|
||||
PublicClass.Companion
|
||||
|
||||
internalFun(internalVal)
|
||||
|
||||
return i
|
||||
}
|
||||
Reference in New Issue
Block a user