/** * Pure evaluator for the lint engine. * * `evaluateContexts(rules, contexts, config)` pairs each rule with each context, * invokes `rule.check`, applies permitted severity overrides from * `config.rules`, and drops warning findings configured `"off"`. * * Both functions are plain `Effect` values; neither requires a Layer or an * ambient service. See the `lint-engine` design doc ยง3 for the rationale * behind library primitives over a central engine service. * * @experimental This API is unstable and may change without notice. * @packageDocumentation */ import * as Effect from "effect/Effect"; import type { LintConfig } from "./config.js"; import type { LintFinding, LintRule } from "./rule.js"; /** * One `(rule, context, findings)` evaluation result. * * `findings` is emitted after severity overrides from `config.rules` have been * applied; rule-level severity is the platform default, finding-level severity * is the effective post-override severity. * * @experimental This API is unstable and may change without notice. */ export interface Evaluated { readonly rule: LintRule; readonly context: C; readonly findings: ReadonlyArray; } /** * Pair each rule with each context, run `rule.check`, apply severity overrides * from `config.rules`, and return one `Evaluated` per pair. * * Findings whose configured severity is `"off"` are suppressed entirely; the * `Evaluated` entry still ships (with an empty `findings` array) so consumers * that group by rule still see the rule ran. * * Rules are evaluated in catalog order; contexts are evaluated in caller * order. Rule-context invocation is sequential within a single * `evaluateContexts` call so tests can observe deterministic ordering. * * @experimental This API is unstable and may change without notice. */ export declare const evaluateContexts: (rules: ReadonlyArray>, contexts: ReadonlyArray, config: LintConfig) => Effect.Effect>>; //# sourceMappingURL=evaluate.d.ts.map