import type * as ts from 'typescript'; import type { ParserServices, TSESTreeOptions } from './parser-options'; import type { TSESTree } from './ts-estree'; declare function clearProgramCache(): void; interface EmptyObject { } type AST = TSESTree.Program & (T['comment'] extends true ? { comments: TSESTree.Comment[]; } : EmptyObject) & (T['tokens'] extends true ? { tokens: TSESTree.Token[]; } : EmptyObject); interface ParseAndGenerateServicesResult { ast: AST; services: ParserServices; } declare function parse(code: string, options?: T): AST; declare function clearParseAndGenerateServicesCalls(): void; declare function parseAndGenerateServices(code: ts.SourceFile | string, options: T): ParseAndGenerateServicesResult; export { AST, parse, parseAndGenerateServices, ParseAndGenerateServicesResult, clearProgramCache, clearParseAndGenerateServicesCalls, }; //# sourceMappingURL=parser.d.ts.map