Skip to main content

parity_impl

Attribute Macro parity_impl 

Source
#[parity_impl]
Expand description

Attribute on an impl block. Walks the block’s methods, strips any #[parity(...)] attributes, and emits one inventory::submit! per stripped attribute. The implementation path is Self::fn_name, so the type prefix is auto-derived (the user doesn’t have to repeat it).

Output token stream layout:

<original impl block, with #[parity] attrs removed from methods>
<one inventory::submit! { ParityEntry { ... } } per stripped attr>

The submits sit at module scope next to the impl, which is where inventory::submit! expects them.