MCPcopy Create free account
hub / github.com/colbymchenry/codegraph / push_ref_at

Method push_ref_at

codegraph-kernel/src/lua.rs:176–197  ·  view source on GitHub ↗
(&mut self, from_row: u32, name: &str, kind: &str, node: Node)

Source from the content-addressed store, hash-verified

174 }
175
176 fn push_ref_at(&mut self, from_row: u32, name: &str, kind: &str, node: Node) {
177 let name_ref = self.arena.put(name);
178 self.tables.push_ref(&RefRow {
179 from_idx: from_row,
180 kind: edge_kind_index(kind).unwrap(),
181 line: self.line_of(node),
182 column: self.col_of(node),
183 reference_name: name_ref,
184 candidates: NONE_STR,
185 from_id_str: NONE_STR,
186 });
187 // flushFnRefCandidates' importedNames gate (tree-sitter.ts:661-675):
188 // dotted lua module paths contribute their LAST segment; simple names
189 // (Roblox leaves) pass whole.
190 if kind == "imports" {
191 if util::simple_name().is_match(name) {
192 self.imported_names.insert(name.to_string());
193 } else if let Some(c) = util::qualified_import().captures(name) {
194 self.imported_names.insert(c[1].to_string());
195 }
196 }
197 }
198
199 // --- createNode (tree-sitter.ts:1308) ---------------------------------
200

Callers 2

emit_requireMethod · 0.45
extract_callMethod · 0.45

Calls 6

edge_kind_indexFunction · 0.85
putMethod · 0.80
unwrapMethod · 0.60
push_refMethod · 0.45
line_ofMethod · 0.45
col_ofMethod · 0.45

Tested by

no test coverage detected