Skip to main content

word

Function word 

Source
pub fn word(ident: &Ident) -> Ident
Expand description

The word a variant’s methods are built on — media for Media, type for r#type.

Free rather than only a method on UnionMember, because a front end refusing a variant it did NOT accept as a member still has to name the method that variant would have had: a refusal spelling that word itself would be a second copy of this rule.

Over the RUST spelling, because the methods are Rust and their reader is looking at the variant.