From cec0fc9f3eaa5df8fc2654ce90d87b9be48b16c0 Mon Sep 17 00:00:00 2001 From: Ilya Ryzhenkov Date: Fri, 11 Jul 2014 22:29:47 +0400 Subject: Support functions with receivers. --- src/Model/DocumentationBuilder.kt | 6 ++++++ 1 file changed, 6 insertions(+) (limited to 'src/Model/DocumentationBuilder.kt') diff --git a/src/Model/DocumentationBuilder.kt b/src/Model/DocumentationBuilder.kt index 73f83ff9..464a5ab2 100644 --- a/src/Model/DocumentationBuilder.kt +++ b/src/Model/DocumentationBuilder.kt @@ -26,6 +26,12 @@ class DocumentationBuilderVisitor(val context: BindingContext) : DeclarationDesc return node } + override fun visitReceiverParameterDescriptor(descriptor: ReceiverParameterDescriptor?, data: DocumentationNode?): DocumentationNode? { + val node = DocumentationNode(descriptor!!.getName().asString(), "", DocumentationNodeKind.Receiver) + data?.addReferenceTo(node, DocumentationReferenceKind.Detail) + return node + } + override fun visitValueParameterDescriptor(descriptor: ValueParameterDescriptor?, data: DocumentationNode?): DocumentationNode? { val doc = context.getDocumentation(descriptor!!) val node = DocumentationNode(descriptor.getName().asString(), doc, DocumentationNodeKind.Parameter) -- cgit