typesec-macro
Procedural macros for the typesec ecosystem.
#[derive(TypesecRole)]
Derive the [Role][typesec_core::role::Role] trait for a struct, pulling
permissions and resource patterns from the #[role(...)] attribute:
use TypesecRole;
;
Expands to:
policy! macro
Inline role definitions without a YAML file:
use policy;
policy!
The macro internals are split across [shared] (permission validation and
name casing), [role_derive] (the derive expansion), and [policy_dsl] (the
policy! parser and codegen).