Skip to content

Commit

Permalink
godot-rust#810 Docs comments do not show up if only some of the class…
Browse files Browse the repository at this point in the history
… members/methods are documented

- Document `block_docstring_or_empty` function
  • Loading branch information
Yarwin committed Jul 27, 2024
1 parent f67c934 commit 1d83966
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions godot-core/src/docs.rs
Original file line number Diff line number Diff line change
Expand Up @@ -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}</{tag}>"),
Expand Down

0 comments on commit 1d83966

Please sign in to comment.