Skip to main content

luaur_vm/macros/
saveci.rs

1//! Source: `VM/src/ldo.h` — #define saveci(L, p) ((char*)(p) - (char*)L->base_ci)
2//! (hand-fixed: generated body dereferenced fields off a raw pointer without (* ))
3
4#[allow(non_snake_case)]
5#[macro_export]
6macro_rules! saveci {
7    ($L:expr, $p:expr) => {
8        (($p as *const u8).offset_from((*$L).base_ci as *const u8)) as isize
9    };
10}
11
12pub use saveci;