203 breaking releases

new 0.206.0 Jan 8, 2025
0.204.0 Jan 3, 2025
0.203.0 Dec 20, 2024
0.199.0 Nov 27, 2024
0.5.0 Mar 31, 2022

#878 in Procedural macros

Download history 23221/week @ 2024-09-19 33449/week @ 2024-09-26 20922/week @ 2024-10-03 24427/week @ 2024-10-10 28808/week @ 2024-10-17 22115/week @ 2024-10-24 22771/week @ 2024-10-31 17532/week @ 2024-11-07 56782/week @ 2024-11-14 27441/week @ 2024-11-21 33618/week @ 2024-11-28 37622/week @ 2024-12-05 45751/week @ 2024-12-12 12017/week @ 2024-12-19 4728/week @ 2024-12-26 25497/week @ 2025-01-02

96,646 downloads per month
Used in 132 crates (3 directly)

MIT license

240KB
7K SLoC

deno_ops

proc_macro for generating highly optimized V8 functions from Rust functions.

use deno_core::{op2, extension};

// Declare an op.
#[op2(fast)]
pub fn op_add(a: i32, b: i32) -> i32 {
  a + b
}

// Register with an extension.
extension!(
  math,
  ops = [op_add]
)

Dependencies

~1.3–2MB
~37K SLoC