http_type/box_rwlock/
fn.rs

1use crate::*;
2
3/// Creates a new boxed read-write lock.
4///
5/// # Arguments
6///
7/// - `T` - The data type to be wrapped.
8///
9/// # Returns
10///
11/// - `BoxRwLock<T>` - A new boxed read-write lock.
12#[inline(always)]
13pub fn box_rwlock<T>(data: T) -> BoxRwLock<T> {
14    Box::new(RwLock::new(data))
15}