From 658146291e2bbf3461a2c86f8e8e23cff6b211f6 Mon Sep 17 00:00:00 2001 From: ebraminio Date: Mon, 16 May 2022 18:45:40 +0430 Subject: Don't expose enum constructor arguments to documentations (#2497) * Don't expose enum constructor arguments to documentation Enum constructor arguments is mostly internal detail of enums that isn't supposed to be exposed to clients of some library so let's don't put it in the generated documentations result. --- .../src/main/kotlin/signatures/KotlinSignatureProvider.kt | 11 ----------- .../descriptors/DefaultDescriptorToDocumentableTranslator.kt | 3 +-- 2 files changed, 1 insertion(+), 13 deletions(-) (limited to 'plugins/base/src/main/kotlin') diff --git a/plugins/base/src/main/kotlin/signatures/KotlinSignatureProvider.kt b/plugins/base/src/main/kotlin/signatures/KotlinSignatureProvider.kt index 642c01c3..294c1d24 100644 --- a/plugins/base/src/main/kotlin/signatures/KotlinSignatureProvider.kt +++ b/plugins/base/src/main/kotlin/signatures/KotlinSignatureProvider.kt @@ -78,17 +78,6 @@ class KotlinSignatureProvider(ctcc: CommentsToContentConverter, logger: DokkaLog group(styles = setOf(TextStyle.Block)) { annotationsBlock(e) link(e.name, e.dri, styles = emptySet()) - e.extra[ConstructorValues]?.let { constructorValues -> - constructorValues.values[it]?.let { values -> - list( - elements = values, - prefix = "(", - suffix = ")", - separator = ", ", - separatorStyles = mainStyles + TokenStyle.Punctuation, - ) { highlightValue(it) } - } - } } } } diff --git a/plugins/base/src/main/kotlin/translators/descriptors/DefaultDescriptorToDocumentableTranslator.kt b/plugins/base/src/main/kotlin/translators/descriptors/DefaultDescriptorToDocumentableTranslator.kt index 85ec1d07..fa0a5b48 100644 --- a/plugins/base/src/main/kotlin/translators/descriptors/DefaultDescriptorToDocumentableTranslator.kt +++ b/plugins/base/src/main/kotlin/translators/descriptors/DefaultDescriptorToDocumentableTranslator.kt @@ -321,8 +321,7 @@ private class DokkaDescriptorVisitor( expectPresentInSet = sourceSet.takeIf { isExpect }, extra = PropertyContainer.withAll( descriptor.additionalExtras().toSourceSetDependent().toAdditionalModifiers(), - descriptor.getAnnotations().toSourceSetDependent().toAnnotations(), - ConstructorValues(descriptor.getAppliedConstructorParameters().toSourceSetDependent()) + descriptor.getAnnotations().toSourceSetDependent().toAnnotations() ) ) } -- cgit