Allow opt-in configuration of events to use SmallVec
- Dominant language
- Rust
- Stars
- 48.2k
- Forks
- 4.8k
- Avg merge
- 3d 22h
- Merged PRs (30d)
- 161
Description
## What problem does this solve or what need does it fill?
Events inherently have variable size. This can cause weirdness with cache locality, particularly when they're stored on components ala what is being proposed in #2070.
## What solution would you like?
Provide an ergonomic way to specify that the internal representation of events use a `SmallVec` of configurable size.
This is particularly relevant for the use case in #2070, where many uses of this pattern will store 0-2 events in 99% of cases.
## What alternative(s) have you considered?
None.
## Additional context
This idea came up in [discussion](https://discord.com/channels/691052431525675048/749335865876021248/838100623290269727) with @TheRawMeatball.
Contributor guide
Assessment
This issue has not been assessed yet.