Skip to main content

parse_choices_attr

Function parse_choices_attr 

Source
pub(crate) fn parse_choices_attr(attr: &Attribute) -> Option<Vec<String>>
Expand description

Extracts the list of choice strings from a #[miniextendr(choices("a", "b", "c"))] attribute.

Returns None if the attribute does not contain choices(...) or is not a #[miniextendr(...)] attribute.