Skip to main content

Module ast

Module ast 

Source
Expand description

AST engine: offline, in-process code parsing via tree-sitter.

Provides symbol extraction and structural queries without requiring a running language server. Used as the primary fallback when no LSP is configured, and as a complement to LSP for fast structural analysis.

Re-exports§

pub use parser::has_syntax_errors;
pub use parser::DocstringInfo;

Modules§

parser
Tree-sitter based symbol and docstring extractor.

Functions§

detect_language
Detect the programming language from a file extension.
extract_docstrings
Extract docstrings/comments from a file using tree-sitter.
extract_symbols
Extract top-level symbols from a file using tree-sitter.
extract_symbols_from_text
Extract symbols from already-loaded source text using tree-sitter.