Open
Description
The docs of Vec::truncate say:
"If len is greater than the vector's current length, this has no effect."
And indeed if you look at the source code:
https://doc.rust-lang.org/nightly/src/alloc/vec.rs.html#740-742
There's:
if len > self.len {
return;
}
But isn't it better to use len >= self.len
instead?