Skip to main content

implicit_description_from_attrs

Function implicit_description_from_attrs 

Source
pub(crate) fn implicit_description_from_attrs(
    attrs: &[Attribute],
) -> Option<String>
Expand description

Extract the implicit description from doc attributes (second paragraph).

In roxygen2, the first paragraph is the title and the second paragraph is the description. This function skips the first paragraph (up to the first blank line) and returns the second paragraph.

Returns None if there is no second paragraph, no doc comments, or if docs start with a @tag.