Skip to main content

Module parser

Module parser 

Source
Expand description

TOML configuration parser.

This module handles parsing of the derive_defs.toml configuration file.

§Configuration Format

The configuration file uses TOML format with the following structure:

# Optional: Include definitions from other files
[includes]
common = "shared/common_defs.toml"

# Define derive presets
[defs.serialization]
traits = ["Clone", "Serialize", "Deserialize"]
attrs = ['#[serde(rename_all = "camelCase")]']

[defs.model]
extends = "serialization"  # Inherit from another def
traits = ["Debug", "PartialEq"]

Structs§

Config
Root configuration structure.
Def
A single definition bundle.

Functions§

parse
Parse TOML content from a string.
parse_file
Parse a TOML configuration file.