From 1ce5373a1f6c99d01db2156a833fcd796ef53e27 Mon Sep 17 00:00:00 2001 From: Dmitry Jemerov Date: Tue, 13 Jan 2015 16:19:42 +0100 Subject: code review and fix tests on Windows build agents --- src/Kotlin/DocumentationBuilder.kt | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) (limited to 'src') diff --git a/src/Kotlin/DocumentationBuilder.kt b/src/Kotlin/DocumentationBuilder.kt index b155ebca..a9b017bb 100644 --- a/src/Kotlin/DocumentationBuilder.kt +++ b/src/Kotlin/DocumentationBuilder.kt @@ -212,7 +212,11 @@ class DocumentationBuilder(val session: ResolveSession, val options: Documentati node.appendSupertypes(this) if (getKind() != ClassKind.OBJECT && getKind() != ClassKind.ENUM_ENTRY) { node.appendChildren(getTypeConstructor().getParameters(), DocumentationReference.Kind.Detail) - node.appendChildren(getConstructors(), DocumentationReference.Kind.Member) + val constructorsToDocument = if (getKind() == ClassKind.ENUM_CLASS) + getConstructors().filter { it.getValueParameters().size() > 0 } + else + getConstructors() + node.appendChildren(constructorsToDocument, DocumentationReference.Kind.Member) } node.appendChildren(getDefaultType().getMemberScope().getAllDescriptors(), DocumentationReference.Kind.Member) val classObjectDescriptor = getClassObjectDescriptor() -- cgit