pub type FnArgsVec<T> = SmallVec<[T; 5]>;
Expand description
(internals) Inline arguments storage for function calls.
Exported under the internals
feature only.
Not available under no_closure
.
§Notes
Since most usage of this is during a function call to gather up arguments, this is mostly allocated on the stack, so we can tolerate a larger number of values stored inline.
Most functions have few parameters, but closures with a lot of captured variables can potentially have many. Having a larger inline storage for arguments reduces allocations in scripts with heavy closure usage.
Under no_closure
, this type aliases to StaticVec
instead.
Aliased Type§
struct FnArgsVec<T> { /* private fields */ }