Closed ringabout closed 1 week ago
Thanks for your hard work on this PR! The lines below are statistics of the Nim compiler built from 2bef08774f00692963f2a00243e4287caa7572ee
Hint: mm: orc; opt: speed; options: -d:release 179014 lines; 8.531s; 664.309MiB peakmem
fixes #23742
Before my PR,
setLen(0)
doesn't free buffer ifs != nil
, but it allocated unnecessary memory forstrs
. This PR rectifies this behavior.setLen(0)
no longer allocates memory for uninitialized strs/seqs