/** * CrossFilePass * * Project-level pass that uses the CrossFileResolver to surface taint flows * that cross file boundaries and to map resolved inter-file calls. * * Unlike the single-file AnalysisPass instances, CrossFilePass operates across * the full set of files in a ProjectGraph and is invoked once after all * per-file analyses are complete. * * Depends on: ProjectGraph (with all files registered) */ import type { CrossFileCall, TaintPath, TypeHierarchy } from '../../types/index.js'; import type { ProjectGraph } from '../../graph/project-graph.js'; export interface CrossFilePassResult { /** Inter-file method calls (source file → target file). */ crossFileCalls: CrossFileCall[]; /** Taint paths that cross file boundaries. */ taintPaths: TaintPath[]; /** Type hierarchy across all files. */ typeHierarchy: TypeHierarchy; /** * Set when the cross-file budget (`options.budgetMs`) was exceeded * mid-phase. When `true`, `taintPaths` may be incomplete — remaining * sub-phases were skipped. Added in 3.89.0 (#141). */ budgetExceeded?: boolean; } export interface CrossFilePassOptions { /** * Wall-time budget (ms) for the entire cross-file phase. `0` or `undefined` * disables the breaker (unlimited). On exceed, partial `taintPaths` are * kept, the remaining sub-phases are skipped, and `budgetExceeded` is set. * * Threaded from `AnalyzerOptions.crossFileBudgetMs` (default 300_000ms / * 5 min) in 3.89.0 to mitigate #141 (langchain4j hang). */ budgetMs?: number; } export declare class CrossFilePass { run(projectGraph: ProjectGraph, /** Raw source lines per file (used to populate `code` fields in paths). */ sourceLines: Map, options?: CrossFilePassOptions): CrossFilePassResult; } //# sourceMappingURL=cross-file-pass.d.ts.map