This is a fascinating example of how languages tend to grow up alongside assumed applications for them and, as a result, can have assumptions deeply baked in that challenge using the language in novel applications and environments.
Solving this without pushing too much complexity onto the developer (1) is going to be a fascinating challenge.
(1) What does "too much complexity" look like? The C++ standard library has template arguments for the memory allocation logic. When it's needed, it's very much needed; when it isn't, the existence of that argument was long a tax on comprehending compile-time template errors until tooling caught up with being able to intelligently hide those arguments when they're likely to be noise.