Fix AppendGraph::capacity to actually use the underlying vec's capacity

This commit is contained in:
2026-07-17 09:54:16 +02:00
parent 8c6c98859c
commit 913a9e0baa
+1 -1
View File
@@ -91,7 +91,7 @@ impl GraphTopology for AppendGraph {
} }
fn vertex_capacity(&self) -> usize { fn vertex_capacity(&self) -> usize {
self.vertices.len() self.vertices.capacity()
} }
fn vertex_map<T: Clone>(&self, default: T) -> VertexMap<Self::Vertex, T> { fn vertex_map<T: Clone>(&self, default: T) -> VertexMap<Self::Vertex, T> {