Expand description
§styx-embed-macros
Proc macros for embedding Styx schemas in binaries. Used by styx-embed to compress and embed schema data at compile time.
§Sponsors
Thanks to all individual sponsors:
…along with corporate sponsors:
…without whom this work could not exist.
§License
Licensed under either of:
- Apache License, Version 2.0 (LICENSE-APACHE or http://www.apache.org/licenses/LICENSE-2.0)
- MIT license (LICENSE-MIT or http://opensource.org/licenses/MIT)
at your option. Proc macros for embedding Styx schemas in binaries.
These macros compress schemas at compile time and embed them with a magic header so they can be extracted without execution.
Each schema must have a meta { id ... } block. The ID is used to
generate a unique static name, allowing multiple schemas to coexist
in the same binary.
Macros§
- embed_
file - Embed a schema from a file (reads at compile time).
- embed_
files - Embed multiple schema files (reads at compile time).
- embed_
inline - Embed a schema from an inline string literal.
- embed_
outdir_ file - Embed a schema file from OUT_DIR (for build script output).
- embed_
schema - embed_
schemas