Documentation
¶
Overview ¶
Package godoc extracts documentation text from Go doc comments so host-side analysis can carry it into generated artifacts such as OpenAPI descriptions.
Doc text is kept verbatim (comment markers removed): the Go source is the single source of truth, so no rewording or prefix trimming happens here.
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func Deprecated ¶
Deprecated reports whether doc carries a godoc "Deprecated:" paragraph.
func Split ¶
Split separates doc into its first sentence and the remaining text. The first sentence maps to an OpenAPI summary, the remainder to a description. Either result may be empty.
func Text ¶
func Text(groups ...*ast.CommentGroup) string
Text returns the plain text of the first non-empty comment group. Nil groups are skipped, so callers can pass fallbacks in priority order (for example a TypeSpec doc followed by its GenDecl doc).
Types ¶
This section is empty.