import type { Annotate } from "./annotate"; import type { Kind } from "./kind"; import type { Path } from "./path"; export type AnnotationBrand = { __brand: "annotation" }; export type GuardAnnotate = Annotate; export type Guard = ( node: object, path: Path, annotate: GuardAnnotate, ) => N & AnnotationBrand; export type Subguard = ( node: object, path: Path, annotate: GuardAnnotate, type: N["type"], kind: Kind, ) => N & AnnotationBrand; export type AnyGuard = ( node: object, path: Path, annotate: Annotate, ) => N;