feat: init

This commit is contained in:
2025-12-31 22:35:48 +08:00
commit aab3b3d5c0
21 changed files with 4875 additions and 0 deletions

13
nix-js-macros/src/lib.rs Normal file
View File

@@ -0,0 +1,13 @@
//! This crate provides procedural macros for the nixjit project.
use proc_macro::TokenStream;
mod ir;
/// A procedural macro to reduce boilerplate when defining an Intermediate Representation (IR).
///
/// It generates an enum for the IR, along with `Ref` and `Mut` variants,
/// `From` implementations, and a `ToIr` trait.
#[proc_macro]
pub fn ir(input: TokenStream) -> TokenStream {
ir::ir_impl(input)
}