csv-codegen 0.2.3

A Rust procedural macro that transforms CSV data into safe, zero-cost code. Generate match arms, loops, and nested queries directly from CSV files, ensuring type safety and deterministic code generation.
Documentation
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
error: #find found 4 matching rows, expected exactly 1. Matching rows: row 2: ["1", "citrus", "Orange"], row 3: ["2", "citrus", "Lemon"], row 4: ["3", "citrus", "Lime"], row 5: ["4", "citrus", "Grapefruit"]. Use a more specific filter condition to select one row.
 --> tests/compile_fail/find_multiple_rows.rs:5:64
  |
5 |       csv_template!("../fruits.csv", #find(category == "citrus") {
  |  ________________________________________________________________^
6 | |         const CITRUS_ID: u32 = #({id}_u32);
7 | |     });
  | |_____^

error[E0308]: mismatched types
 --> tests/compile_fail/find_multiple_rows.rs:5:5
  |
5 | /     csv_template!("../fruits.csv", #find(category == "citrus") {
6 | |         const CITRUS_ID: u32 = #({id}_u32);
7 | |     });
  | |______^ expected `u32`, found `&str`
  |
  = note: this error originates in the macro `csv_template` (in Nightly builds, run with -Z macro-backtrace for more info)