MCPcopy Create free account
hub / github.com/concensure/Semantic / last_nested_node

Function last_nested_node

parser/src/lib.rs:972–983  ·  view source on GitHub ↗
(
    nodes: &'a [LogicNodeRecord],
    parent: &LogicNodeRecord,
    idx: usize,
)

Source from the content-addressed store, hash-verified

970}
971
972fn last_nested_node<'a>(
973 nodes: &'a [LogicNodeRecord],
974 parent: &LogicNodeRecord,
975 idx: usize,
976) -> Option<&'a LogicNodeRecord> {
977 nodes
978 .iter()
979 .skip(idx + 1)
980 .take_while(|n| n.start_line <= parent.end_line)
981 .filter(|n| n.end_line <= parent.end_line)
982 .last()
983}
984
985fn first_matching_nested<'a>(
986 nodes: &'a [LogicNodeRecord],

Callers 1

build_control_flow_edgesFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…