Macro smallvec_inline
macro_rules! smallvec_inline {
(@one $x:expr) => { ... };
($elem:expr; $n:expr) => { ... };
($($x:expr),+ $(,)?) => { ... };
}
Creates an inline SmallVec containing the arguments. This macro is enabled by the feature const_new.
smallvec_inline! allows SmallVecs to be defined with the same syntax as array expressions in const contexts.
The inline storage A will always be an array of the size specified by the arguments.
There are two forms of this macro:
- Create a
SmallVeccontaining a given list of elements:
# use ;
#
- Create a
SmallVecfrom a given element and size:
# use ;
#
Note that the behavior mimics that of array expressions, in contrast to smallvec.