pub struct RawNode {
pub language: Language,
pub kind: NodeKind,
pub name: Option<String>,
pub usr: Option<String>,
pub start_line: usize,
pub start_col: usize,
pub end_line: usize,
pub end_col: usize,
pub children: Vec<usize>,
pub source_file: Option<String>,
}Expand description
A single fact extracted from source code by a language parser.
RawNode is a language‑agnostic representation of an AST node. It
captures the kind of the node, its location, an optional name, and
structural relationships through children. The source_file field
allows the graph builder to filter out external headers when desired.
Fields§
§language: LanguageProgramming language of the source file.
kind: NodeKindKind of the node (function, class, call, etc.).
name: Option<String>Optional human‑readable name (e.g., function name).
usr: Option<String>Optional unique symbol identifier for cross‑file references.
start_line: usize1‑based line where this node starts.
start_col: usize0‑based column where this node starts.
end_line: usize1‑based line where this node ends.
end_col: usize0‑based column where this node ends.
children: Vec<usize>Indices of child RawNodes (in the same file) that are directly
nested under this node according to the AST.
source_file: Option<String>Path to the source file, if known. Used for filtering system headers.