diff options
-rw-r--r-- | src/Formats/StructuredFormatService.kt | 10 | ||||
-rw-r--r-- | test/data/format/enumClass.md | 4 | ||||
-rw-r--r-- | test/data/format/extensions.package.md | 2 |
3 files changed, 10 insertions, 6 deletions
diff --git a/src/Formats/StructuredFormatService.kt b/src/Formats/StructuredFormatService.kt index a3803011..233dd9e3 100644 --- a/src/Formats/StructuredFormatService.kt +++ b/src/Formats/StructuredFormatService.kt @@ -232,9 +232,13 @@ public abstract class StructuredFormatService(locationService: LocationService, for ((summary, items) in breakdownBySummary) { val signatureTexts = items map { signature -> val signatureText = languageService.render(signature, RenderMode.SUMMARY) - val signatureAsCode = ContentCode() - signatureAsCode.append(signatureText) - formatText(location, signatureAsCode) + if (signatureText is ContentBlock && signatureText.isEmpty()) { + "" + } else { + val signatureAsCode = ContentCode() + signatureAsCode.append(signatureText) + formatText(location, signatureAsCode) + } } signatureTexts.subList(0, signatureTexts.size()-1).forEach { appendAsSignature(to) { diff --git a/test/data/format/enumClass.md b/test/data/format/enumClass.md index 09efc792..da1ef851 100644 --- a/test/data/format/enumClass.md +++ b/test/data/format/enumClass.md @@ -10,6 +10,6 @@ ### Enum Values -| [LOCAL_CONTINUE_AND_BREAK](test/-inline-option/-l-o-c-a-l_-c-o-n-t-i-n-u-e_-a-n-d_-b-r-e-a-k) | `` | -| [ONLY_LOCAL_RETURN](test/-inline-option/-o-n-l-y_-l-o-c-a-l_-r-e-t-u-r-n) | `` | +| [LOCAL_CONTINUE_AND_BREAK](test/-inline-option/-l-o-c-a-l_-c-o-n-t-i-n-u-e_-a-n-d_-b-r-e-a-k) | | +| [ONLY_LOCAL_RETURN](test/-inline-option/-o-n-l-y_-l-o-c-a-l_-r-e-t-u-r-n) | | diff --git a/test/data/format/extensions.package.md b/test/data/format/extensions.package.md index d4ab577e..b4596b80 100644 --- a/test/data/format/extensions.package.md +++ b/test/data/format/extensions.package.md @@ -10,5 +10,5 @@ ### Extensions for External Classes -| [String](test/foo/-string/index) | `` | +| [String](test/foo/-string/index) | | |