Macro abi_stable::rvec

source ·
macro_rules! rvec {
    ( $( $anything:tt )* ) => { ... };
}
Expand description

Constructs an RVec using the same syntax that the std::vec macro uses.

Example


use abi_stable::{
    rvec,
    std_types::RVec,
};

assert_eq!(RVec::<u32>::new(), rvec![]);
assert_eq!(RVec::from(vec![0]), rvec![0]);
assert_eq!(RVec::from(vec![0, 3]), rvec![0, 3]);
assert_eq!(RVec::from(vec![0, 3, 6]), rvec![0, 3, 6]);
assert_eq!(RVec::from(vec![1; 10]), rvec![1; 10]);