Everyone seems to love smallvec, but I haven't yet had the chance to use it in a project. Keeping things off the heap generally seems like a good idea, so I'd like to try it.
Here's the thing: when is it "morally" right to use
smallvec? I don't mean "technically". I know what it's for and how to use it. But when would its use be considered a premature optimization? If a datatype I only use once, saying during program initialization, contains a
Vec, would there really be a point in making that a
Please and thanks.