9 releases
new 0.2.2 | Mar 20, 2023 |
---|---|
0.2.1 | Mar 20, 2023 |
0.1.5 | Mar 19, 2023 |
0.1.2 | Dec 8, 2022 |
#92 in FFI
1,246 downloads per month
180KB
5K
SLoC
cmacro
This is a library for parsing C macros and converting them to Rust functions or macros.
lib.rs
:
A library for parsing C macros.
This crate allows parsing C macros and converting them to Rust code.
Both function-like macros (e.g. #define FUNC(a, b, c) a + b * c
) as well
as variable-like macros (e.g. #define VAR 4 + 7 * 82
) are supported.
See [FnMacro
] and [VarMacro
] on how to parse macros.
Dependencies
~1.5–2MB
~43K SLoC