MCPcopy Create free account
hub / github.com/AmrDeveloper/GQL / compare

Method compare

crates/gitql-core/src/values/boolean.rs:42–47  ·  view source on GitHub ↗
(&self, other: &Box<dyn Value>)

Source from the content-addressed store, hash-verified

40 }
41
42 fn compare(&self, other: &Box<dyn Value>) -> Option<Ordering> {
43 if let Some(other_bool) = other.as_any().downcast_ref::<BoolValue>() {
44 return self.value.partial_cmp(&other_bool.value);
45 }
46 None
47 }
48
49 fn data_type(&self) -> Box<dyn DataType> {
50 Box::new(BoolType)

Callers

nothing calls this directly

Calls 2

as_anyMethod · 0.45
partial_cmpMethod · 0.45

Tested by

no test coverage detected