Add Default trait to GraphTopologyAddition

This commit is contained in:
2026-08-27 20:11:54 +02:00
parent cbabb8f960
commit 1185e3b667
+1 -1
View File
@@ -178,7 +178,7 @@ pub trait GraphTopology {
/// ///
/// This trait provides methods for addition of vertices and edges, and capacity management in an /// This trait provides methods for addition of vertices and edges, and capacity management in an
/// undirected graph. /// undirected graph.
pub trait GraphTopologyAddition: GraphTopology { pub trait GraphTopologyAddition: GraphTopology + Default {
/// Returns the total number of vertices the graph can hold without reallocating. /// Returns the total number of vertices the graph can hold without reallocating.
fn vertex_capacity(&self) -> usize; fn vertex_capacity(&self) -> usize;