From 3ee08cbce94a4e7e1ce668f06f5a612cd9f1e677 Mon Sep 17 00:00:00 2001 From: Jonas Herzig Date: Fri, 12 Nov 2021 12:58:49 +0100 Subject: Fix mapping of synthetic properties when overridden in Kotlin class In these cases, the getMethod of the property will not have a Psi element and we need to traverse up the overrides until we find one that does. --- src/testB/kotlin/bMarker.kt | 3 +++ src/testB/kotlin/pkg/Kt.kt | 12 ++++++++++++ 2 files changed, 15 insertions(+) create mode 100644 src/testB/kotlin/bMarker.kt create mode 100644 src/testB/kotlin/pkg/Kt.kt (limited to 'src/testB/kotlin') diff --git a/src/testB/kotlin/bMarker.kt b/src/testB/kotlin/bMarker.kt new file mode 100644 index 0000000..b56de50 --- /dev/null +++ b/src/testB/kotlin/bMarker.kt @@ -0,0 +1,3 @@ +@file:Suppress("unused") // Exists only so we can find the testB/kotlin classes on the classpath + +private const val dummy = 1 diff --git a/src/testB/kotlin/pkg/Kt.kt b/src/testB/kotlin/pkg/Kt.kt new file mode 100644 index 0000000..7e75181 --- /dev/null +++ b/src/testB/kotlin/pkg/Kt.kt @@ -0,0 +1,12 @@ +package pkg + +import b.pkg.B + +class Kt : B() { + override fun getSyntheticB(): B { + return this + } + + override fun setSyntheticB(arg: B) { + } +} \ No newline at end of file -- cgit