22 unstable releases (8 breaking)

0.12.2 Jun 10, 2024
0.11.3 Feb 11, 2024
0.11.1 Dec 26, 2023
0.10.1 Nov 14, 2023
0.6.1 Mar 13, 2023

#1569 in Procedural macros

Download history 28/week @ 2024-07-30 3/week @ 2024-09-17 37/week @ 2024-09-24 1/week @ 2024-10-01 1/week @ 2024-10-08 1/week @ 2024-10-15

1,259 downloads per month

Apache-2.0

735KB
18K SLoC

Macros for PRQL compilation at build time.

use prql_compiler_macros::prql_to_sql;

let sql: &str = prql_to_sql!("from albums | select {title, artist_id}");
assert_eq!(sql, "SELECT title, artist_id FROM albums");

"at build time" means that PRQL will be compiled during Rust compilation, producing errors alongside Rust errors. Limited to string literals.

Dependencies

~10–19MB
~251K SLoC