C Support in Maguyva: Call Graphs for Systems and Embedded Code
In C, the call graph is the architecture. An agent should read it before it edits.
Extensions
.c, .h
Maguyva parses Lua with AST, symbol, and graph support, so AI agents can follow modules, colon methods, metatable classes, and require chains in Lua code.
Lua has no class keyword. Objects are tables, methods are functions stored in them, and inheritance is a setmetatable call. A module is whatever require returns. The structure is real, but it lives in conventions that text search does not understand.
Maguyva reads those conventions as structure, so an agent can ask who calls a method or which tables extend a base and get a direct answer.
Maguyva covers .lua files. Function declarations, local function definitions, and function expressions are extracted, and colon methods such as function Account:deposit() are attributed to their owning table, Account. Method chains are followed call by call, and calls on self stay tied to the enclosing object.
Lua’s conventions map onto relationships:
require, dofile, and loadfile record imports.setmetatable call records inheritance.ClassName:new(), ClassName.new(), and setmetatable({...}, ClassName) count as instantiation.error() records a throw, and pcall and xpcall record a catch.The graph also records reads and writes and control flow.
Inventory:addItem, and from which scripts?” (find_symbol, then dependency_search incoming)util.http?” (dependency_search)get_task_context)string, table, math, io, os, coroutine, debug, and utf8) plus the Neovim vim.* and OpenResty ngx.* APIs. Calls into those APIs are not graph edges, so use text_pattern_search to find them.classes and imports presets in structural_search select nothing for Lua. Use find_symbol or text_pattern_search instead.Connect a repository with the quickstart, then check the support matrix on the compatibility page. For engines that embed Lua in native code, read the C guide too.
Best fit
Agent workflows
Engine details
Useful MCP entry points
Use it for a module function or colon method when you need the definition and callers.
Use incoming traversal on a shared module to see which files require it before moving it.
Use it for calls into `vim.*`, `ngx.*`, or the standard library, which are filtered from the graph.
Related guides
In C, the call graph is the architecture. An agent should read it before it edits.
Extensions
.c, .h
Useful when Python codebases sprawl across services, scripts, type stubs, and operational glue.
Extensions
.py, .pyi, .pyw