MCPcopy Create free account
hub / github.com/QMHTMY/RustBook / cmp

Method cmp

publication/code/chapter09/dijkstra.rs:27–29  ·  view source on GitHub ↗
(&self, other: &Self)

Source from the content-addressed store, hash-verified

25// 为 Visited 添加全序比较功能
26impl<V> Ord for Visited<V> {
27 fn cmp(&self, other: &Self) -> Ordering {
28 other.distance.cmp(&self.distance)
29 }
30}
31
32impl<V> PartialOrd for Visited<V> {

Callers 12

bucket_sortFunction · 0.45
partial_cmpMethod · 0.45
containsMethod · 0.45
getMethod · 0.45
containsMethod · 0.45
insertMethod · 0.45
containsMethod · 0.45
containsMethod · 0.45
getMethod · 0.45
get_mutMethod · 0.45
insertMethod · 0.45
deleteMethod · 0.45

Calls

no outgoing calls

Tested by

no test coverage detected