Expand description
§Patchable Macro
Procedural macros backing the patchable crate.
Provided macros:
-
#[patchable_model]: injectsPatchable/Patchderives; with theserdeCargo feature enabled for this macro crate it also addsserde::Serializeand applies#[serde(skip)]to fields marked#[patchable(skip)]. -
#[derive(Patchable)]: generates the companion<Struct>Patchtype and thePatchableimpl; with theimpl_fromCargo feature it also generatesFrom<Struct>for the patch type. -
#[derive(Patch)]: generates thePatchimplementation and recursively patches fields annotated with#[patchable].
Feature flags are evaluated in the patchable-macro crate itself. See context
for details about the generated patch struct and trait implementations.
Attribute Macros§
- patchable_
model - Attribute macro that augments a struct with Patchable/Patch derives.