diff options
author | Simon Ogorodnik <Simon.Ogorodnik@jetbrains.com> | 2017-11-21 02:58:34 +0300 |
---|---|---|
committer | Simon Ogorodnik <Simon.Ogorodnik@jetbrains.com> | 2017-11-21 02:58:34 +0300 |
commit | 924832f8ae7a38ad7c6b105c04794195bf9d4f9f (patch) | |
tree | 2a13e68fb46d2423ddf4d760c89ab36a22b37f8c /core/src | |
parent | d0d5617669217c095858df0b5f1597aa5c230dcf (diff) | |
download | dokka-924832f8ae7a38ad7c6b105c04794195bf9d4f9f.tar.gz dokka-924832f8ae7a38ad7c6b105c04794195bf9d4f9f.tar.bz2 dokka-924832f8ae7a38ad7c6b105c04794195bf9d4f9f.zip |
More info in can't find node by signature
Diffstat (limited to 'core/src')
-rw-r--r-- | core/src/main/kotlin/Kotlin/DeclarationLinkResolver.kt | 11 |
1 files changed, 10 insertions, 1 deletions
diff --git a/core/src/main/kotlin/Kotlin/DeclarationLinkResolver.kt b/core/src/main/kotlin/Kotlin/DeclarationLinkResolver.kt index 275972fa..24f50dac 100644 --- a/core/src/main/kotlin/Kotlin/DeclarationLinkResolver.kt +++ b/core/src/main/kotlin/Kotlin/DeclarationLinkResolver.kt @@ -32,7 +32,16 @@ class DeclarationLinkResolver return ContentExternalLink(externalHref) } val signature = descriptorSignatureProvider.signature(symbol) - return ContentNodeLazyLink(href, { -> refGraph.lookupOrWarn(signature, logger) }) + val referencedAt = fromDescriptor.sourceLocation()?.let { ", referenced at $it" }.orEmpty() + + return ContentNodeLazyLink(href, { -> + val target = refGraph.lookup(signature) + + if (target == null) { + logger.warn("Can't find node by signature $signature$referencedAt") + } + target + }) } if ("/" in href) { return ContentExternalLink(href) |