From 48167ef4c63e287868fc2a435de6822ede625df2 Mon Sep 17 00:00:00 2001 From: Simon Ogorodnik Date: Wed, 14 Dec 2016 15:38:53 +0300 Subject: Fix for GH-90 --- core/src/main/kotlin/javadoc/docbase.kt | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) (limited to 'core/src') diff --git a/core/src/main/kotlin/javadoc/docbase.kt b/core/src/main/kotlin/javadoc/docbase.kt index eafa216b..65b28a42 100644 --- a/core/src/main/kotlin/javadoc/docbase.kt +++ b/core/src/main/kotlin/javadoc/docbase.kt @@ -209,8 +209,12 @@ open class TypeAdapter(override val module: ModuleNodeAdapter, override val node override fun equals(other: Any?): Boolean = other is TypeAdapter && toString() == other.toString() } +class NotAnnotatedTypeAdapter(typeAdapter: AnnotatedTypeAdapter) : Type by typeAdapter { + override fun asAnnotatedType() = null +} + class AnnotatedTypeAdapter(module: ModuleNodeAdapter, node: DocumentationNode) : TypeAdapter(module, node), AnnotatedType { - override fun underlyingType(): Type? = this + override fun underlyingType(): Type? = NotAnnotatedTypeAdapter(this) override fun annotations(): Array = nodeAnnotations(this).toTypedArray() } -- cgit