forked from Orchid/orchid
Formatter introduced
This commit is contained in:
9
orchid-base/src/tl_cache.rs
Normal file
9
orchid-base/src/tl_cache.rs
Normal file
@@ -0,0 +1,9 @@
|
||||
#[macro_export]
|
||||
macro_rules! tl_cache {
|
||||
($ty:ty : $expr:expr) => {{
|
||||
thread_local! {
|
||||
static V: $ty = $expr;
|
||||
}
|
||||
V.with(|v| v.clone())
|
||||
}};
|
||||
}
|
||||
Reference in New Issue
Block a user