import type { StaleFileComposition, StaleRegionComposition } from '../../types/index.js'; import type { FunctionNode } from './call-graph-types.js'; export type { StaleFileComposition, StaleRegionComposition, StaleRegionSymbol } from '../../types/index.js'; export interface ClosureFileSignificance { path: string; fanIn: number; fanOut: number; hasInternalNode: boolean; isTest: boolean; } /** Strict file order: fan-in desc, same winning node's fan-out desc, path asc. */ export declare function compareClosureSignificance(a: ClosureFileSignificance, b: ClosureFileSignificance): number; /** * Aggregate symbol facts to files. The maximum-fan-in internal non-test node * wins; its fan-out breaks that tie. Files without such a node rank last. */ export declare function closureFileSignificance(paths: readonly string[], nodes: readonly FunctionNode[]): ClosureFileSignificance[]; /** * Spend one phase's budget deterministically. Under budget the input order is * returned untouched. Over budget, test candidates rank within their own class * and receive one slot when both classes are present, preventing systematic * test-to-production reachability starvation without changing the work count. */ export declare function spendClosureBudget(candidates: readonly string[], budget: number, nodes: readonly FunctionNode[]): { selected: string[]; dropped: string[]; usedPathFallback: boolean; testReachabilityDegraded: boolean; }; /** Compute per-file receipts so clearing one stale file also clears its contribution. */ export declare function composeStaleFiles(files: readonly string[], nodes: readonly FunctionNode[]): Map; /** Combine persisted per-file receipts into the reported stale-region composition. */ export declare function combineStaleFileCompositions(files: readonly StaleFileComposition[], fileCount?: number): StaleRegionComposition; /** Render repository-derived names through the shared terminal safety boundary. */ export declare function formatStaleRegionComposition(composition: StaleRegionComposition): string; //# sourceMappingURL=incremental-closure.d.ts.map