Skip to main content

cpp_same_node

Function cpp_same_node 

Source
pub fn cpp_same_node(left: Node<'_>, right: Node<'_>) -> bool
Expand description

Whether left and right are the same syntax node, by tree-sitter node identity. Exact where a byte-range comparison can collide a unit/wrapper node with its sole child (which share an identical span); both nodes must come from the same tree for the ids to be comparable.