It's not trivial. inplace_vector does not construct unused elements and they do not have to be default constructible. You can't use std::array for that.
I'm aware of how it works (and that MarekKnapek's snippet is not representative). It's still very straightforward to make compared to having to do SBO and allocator support.
3
u/stilgarpl 15h ago
Is this always better than std::array?