From 82d62bc02d17f41659e2fa76224827cbaa027633 Mon Sep 17 00:00:00 2001 From: Joseph Crail Date: Tue, 16 Sep 2025 15:15:45 -0700 Subject: [PATCH] Update documentation for number of edges The documentation for `Graph.number_of_edges` incorrectly referred to `Graph.number_of_nodes`. --- src/graph/query.rs | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/graph/query.rs b/src/graph/query.rs index 4820bdc..99bf91a 100644 --- a/src/graph/query.rs +++ b/src/graph/query.rs @@ -1034,11 +1034,11 @@ where } /** - Returns the number of nodes in the graph. + Returns the number of edges in the graph. ``` use graphrs::{generators}; let graph = generators::social::karate_club_graph(); - assert_eq!(graph.number_of_nodes(), 34); + assert_eq!(graph.number_of_edges(), 34); ``` */ pub fn number_of_edges(&self) -> usize {