From 1d83966f637f21e2737a29fda5b62e11c2b4b590 Mon Sep 17 00:00:00 2001 From: Yarvin Date: Sat, 27 Jul 2024 12:25:25 +0200 Subject: [PATCH] #810 Docs comments do not show up if only some of the class members/methods are documented - Document `block_docstring_or_empty` function --- godot-core/src/docs.rs | 3 +++ 1 file changed, 3 insertions(+) diff --git a/godot-core/src/docs.rs b/godot-core/src/docs.rs index 8a2dcb662..40fdbb0c9 100644 --- a/godot-core/src/docs.rs +++ b/godot-core/src/docs.rs @@ -46,6 +46,9 @@ struct DocPieces { virtual_methods: Option<&'static str>, } +#[doc(hidden)] +/// Generates documentation for given block if there is anything to document +/// Returns empty string otherwise fn block_docstring_or_empty(block: Option<&'static str>, tag: &'static str) -> String { match block { Some(s) => format!("<{tag}>{s}"),