4 ms·
That would be true if you used `Vec::clear` too, it doesn't allocate a new vector. My point was that you still end up running Drop implementations with Repeated
by K0nserv 3y ago
That would be true if you used `Vec::clear` too, it doesn't allocate a new vector. My point was that you still end up running Drop implementations with RepeatedField<T>, just not all at once. See https://play.rust-lang.org/?version=stable&mode=debug&edition=2021&gist=75621151b0a3e81da16741a24f8f9e96 https://play.rust-lang.org/?version=stable&mode=debug&editio...