Skip to main content

embedded_config

Macro embedded_config 

Source
macro_rules! embedded_config {
    ($(#[$attribute:meta])* $visibility:vis static $name:ident: $type:ty = $text:expr;) => { ... };
    (copy;
        $(#[$attribute:meta])* $visibility:vis struct $name:ident {
            $($(#[$field_attribute:meta])* $field_visibility:vis $field:ident: $type:ty,)*
        }
        defaults = $text:expr;
    ) => { ... };
}
Expand description

Declares defaulted settings backed by a complete owner-local TOML document.

The private complete decoder does not invoke Default, preventing recursive initialization when Serde fills omitted external settings. Use copy; for settings containing only Copy fields. A static NAME: Type = text; declaration shares the same loader for complete embedded catalogs without adding external deserialization defaults.