-
Notifications
You must be signed in to change notification settings - Fork 5.8k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
JVM KT-49613 don't generate indy reference to protected constructor
- Loading branch information
Showing
7 changed files
with
62 additions
and
3 deletions.
There are no files selected for viewing
6 changes: 6 additions & 0 deletions
6
.../tests-gen/org/jetbrains/kotlin/test/runners/codegen/FirBlackBoxCodegenTestGenerated.java
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
28 changes: 28 additions & 0 deletions
28
compiler/testData/codegen/box/invokedynamic/sam/functionRefToJavaInterface/kt49613.kt
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,28 @@ | ||
// TARGET_BACKEND: JVM | ||
// JVM_TARGET: 1.8 | ||
// SAM_CONVERSIONS: INDY | ||
// FILE: kt49613.kt | ||
|
||
interface GetStep { | ||
fun get(): Any | ||
} | ||
|
||
class Outer protected constructor(val ok: Any) { | ||
constructor(): this("xxx") | ||
|
||
val obj = object : GetStep { | ||
override fun get() = Step(::Outer) | ||
} | ||
} | ||
|
||
fun box(): String { | ||
val s = Outer().obj.get() as Step | ||
val t = s.step("OK") as Outer | ||
return t.ok as String | ||
} | ||
|
||
// FILE: Step.java | ||
|
||
public interface Step { | ||
Object step(String string); | ||
} |
6 changes: 6 additions & 0 deletions
6
...new/tests-gen/org/jetbrains/kotlin/test/runners/codegen/BlackBoxCodegenTestGenerated.java
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
6 changes: 6 additions & 0 deletions
6
...w/tests-gen/org/jetbrains/kotlin/test/runners/codegen/IrBlackBoxCodegenTestGenerated.java
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
5 changes: 5 additions & 0 deletions
5
compiler/tests-gen/org/jetbrains/kotlin/codegen/LightAnalysisModeTestGenerated.java
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.