ordo-derive 0.2.0

Procedural macros for the Ordo rule engine — #[derive(TypedContext)] for schema-aware JIT
Documentation
  • Coverage
  • 100%
    3 out of 3 items documented0 out of 2 items with examples
  • Size
  • Source code size: 15.15 kB This is the summed size of all the files inside the crates.io package for this release.
  • Documentation size: 308.22 kB This is the summed size of all files generated by rustdoc for all configured targets
  • Ø build duration
  • this release: 7s Average build duration of successful builds.
  • all releases: 7s Average build duration of successful builds in releases after 2024-10-23.
  • Links
  • Homepage
  • Ordo-Engine/Ordo
    29 6 0
  • crates.io
  • Dependencies
  • Versions
  • Owners
  • Pama-Lee

Procedural macros for Ordo rule engine

This crate provides derive macros for generating TypedContext implementations that enable zero-overhead field access in JIT-compiled code.

Usage

use ordo_derive::TypedContext;

#[derive(TypedContext)]
#[repr(C)]  // Recommended for stable layout
pub struct LoanContext {
    pub amount: f64,
    pub credit_score: i32,
    pub approved: bool,
}

The macro generates an implementation of TypedContext that provides:

  • A static MessageSchema describing the struct layout
  • Direct field pointer access via field_ptr()
  • Nested field path resolution (for nested structs)