macro_rules! register_nodes {
($sigs:expr, $builder:expr) => { ... };
($sigs:expr, $builder:expr, $validator:expr) => { ... };
}Expand description
Register a node module’s signatures and builder with the Polydat runtime.
Place this call at module scope in each node module. The inventory crate
arranges for the registration to run before main so that registry()
and build_node() see all entries.
Two forms:
register_nodes!(signatures, build_node)— no assembly-time validation. The builder is responsible for handling any bad input itself (usually by trusting the caller or panicking).register_nodes!(signatures, build_node, validate_node)— the factory callsvalidate_node(name, consts)beforebuild_node. Use this to declareConstConstraint-style checks so constructors can stay infallible.