#[non_exhaustive]pub struct ParseOptions {
pub roxygen_markdown_default: bool,
}Expand description
Options controlling a parse. Construct via Default and set the fields
you need — the struct is #[non_exhaustive], so new options can be added
without a breaking change.
Fields (Non-exhaustive)§
This struct is marked as non-exhaustive
Struct { .. } syntax; cannot be matched against without a wildcard ..; and struct update syntax will not work.roxygen_markdown_default: boolThe markdown mode of a roxygen block carrying no @md/@noMd
directive of its own (a block’s directive always wins, last one in the
block winning — roxygen2’s block-level toggle).
Off means Rd-first, matching parse and roxygen2’s loose-file
default. Since roxygen2 8.0.0 packages normally enable markdown
package-wide (Config/roxygen2/markdown in DESCRIPTION, or the older
Roxygen: list(markdown = TRUE) field) rather than writing per-block
@md, so a caller processing such a package should set this to true.
Discovering the setting from DESCRIPTION is the caller’s job — this
crate never does file I/O beyond the text it is handed.
Implementations§
Source§impl ParseOptions
impl ParseOptions
Sourcepub fn with_roxygen_markdown_default(self, on: bool) -> Self
pub fn with_roxygen_markdown_default(self, on: bool) -> Self
Builder-style setter for roxygen_markdown_default: the struct is
#[non_exhaustive], so outside this crate
ParseOptions::default().with_roxygen_markdown_default(true) is the way
to construct an options value with markdown on.