Files
orchid/orchid-base/src/tl_cache.rs

10 lines
148 B
Rust

#[macro_export]
macro_rules! tl_cache {
($ty:ty : $expr:expr) => {{
thread_local! {
static V: $ty = $expr;
}
V.with(|v| v.clone())
}};
}