diff options
author | Andrzej Ratajczak <andrzej.ratajczak98@gmail.com> | 2020-08-20 13:59:58 +0200 |
---|---|---|
committer | Paweł Marks <Kordyjan@users.noreply.github.com> | 2020-08-20 15:36:07 +0200 |
commit | b9a1b3380a0bb8a64f3c7f257374cd4a6b2f3cfe (patch) | |
tree | 2417b1065167353cf09751ecd5d07d6f624bc4d8 /plugins/base/src/main | |
parent | fab2d4ba4f13454ab36ea7ee333579bf3441f2ed (diff) | |
download | dokka-b9a1b3380a0bb8a64f3c7f257374cd4a6b2f3cfe.tar.gz dokka-b9a1b3380a0bb8a64f3c7f257374cd4a6b2f3cfe.tar.bz2 dokka-b9a1b3380a0bb8a64f3c7f257374cd4a6b2f3cfe.zip |
Fix requested bugfixes
Diffstat (limited to 'plugins/base/src/main')
-rw-r--r-- | plugins/base/src/main/kotlin/signatures/JvmSignatureUtils.kt | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/plugins/base/src/main/kotlin/signatures/JvmSignatureUtils.kt b/plugins/base/src/main/kotlin/signatures/JvmSignatureUtils.kt index 0defc69e..f934faa5 100644 --- a/plugins/base/src/main/kotlin/signatures/JvmSignatureUtils.kt +++ b/plugins/base/src/main/kotlin/signatures/JvmSignatureUtils.kt @@ -136,9 +136,11 @@ interface JvmSignatureUtils { || it.dri == DRI("java.lang", "Deprecated") } == true) setOf(TextStyle.Strikethrough) else emptySet() - infix fun DFunction.uses(t: DTypeParameter): Boolean = - t.dri in (listOfNotNull(receiver?.type?.drisOfAllNestedBounds, receiver?.dri) + + infix fun DFunction.uses(t: DTypeParameter): Boolean { + val allDris: List<DRI> = (listOfNotNull(receiver?.dri, *receiver?.type?.drisOfAllNestedBounds?.toTypedArray() ?: emptyArray()) + parameters.flatMap { listOf(it.dri) + it.type.drisOfAllNestedBounds }) + return t.dri in allDris + } } sealed class AtStrategy |