Returns the current parent node ID, or None if at file root level.
(&self)
| 69 | |
| 70 | /// Returns the current parent node ID, or None if at file root level. |
| 71 | fn parent_node_id(&self) -> Option<&str> { |
| 72 | self.node_stack.last().map(|(_, id)| id.as_str()) |
| 73 | } |
| 74 | |
| 75 | /// Gets the text of a tree-sitter node from the source. |
| 76 | fn node_text(&self, node: TsNode<'_>) -> String { |
no test coverage detected