grammers icon indicating copy to clipboard operation
grammers copied to clipboard

Investigate reducing number of allocations for raw types

Open Lonami opened this issue 3 years ago • 0 comments

Currently, every raw type is owned. This makes it very convenient to use (both for reading, and for creating instances of it, e.g. to send requests). However, it's also pretty wasteful.

One alternative would be to only store references to the buffer (so when the objects are deserialized, references are created into the buffer, which would be kept alive until dropped), although this may not be worth the trouble, since the only thing really needing allocations are String and Vec.

Lonami avatar May 30 '21 16:05 Lonami