From 5fab72fae42209efb9e491537a11561447c1e0cd Mon Sep 17 00:00:00 2001 From: Nathan Shively-Sanders <293473+sandersn@users.noreply.github.com> Date: Tue, 1 May 2018 10:16:47 -0700 Subject: [PATCH] Add types --- src/compiler/types.ts | 16 ++++++++++++++++ 1 file changed, 16 insertions(+) diff --git a/src/compiler/types.ts b/src/compiler/types.ts index 3608b6b5c32..d71aa8404e2 100644 --- a/src/compiler/types.ts +++ b/src/compiler/types.ts @@ -411,9 +411,11 @@ namespace ts { JSDocVariadicType, JSDocComment, JSDocTypeLiteral, + JSDocSignature, JSDocTag, JSDocAugmentsTag, JSDocClassTag, + JSDocCallbackTag, JSDocParameterTag, JSDocReturnTag, JSDocTypeTag, @@ -822,6 +824,7 @@ namespace ts { | FunctionTypeNode | ConstructorTypeNode | JSDocFunctionType + | JSDocSignature // TODO: Different from JSDocFunctionType?????? | FunctionDeclaration | MethodDeclaration | ConstructorDeclaration @@ -2385,6 +2388,19 @@ namespace ts { typeExpression?: JSDocTypeExpression | JSDocTypeLiteral; } + export interface JSDocCallbackTag extends JSDocTag, NamedDeclaration { + parent: JSDoc; + kind: SyntaxKind.JSDocCallbackTag; + fullName?: JSDocNamespaceDeclaration | Identifier; + name?: Identifier; // TODO: Not sure whether this rigamarole is needed for callback...but probably! + signature: JSDocSignature; + } + + // TODO: name it JSDocSignatureDeclaration? Could just try to reuse JSDocTypeLiteral + export interface JSDocSignature extends JSDocType, SignatureDeclarationBase { + kind: SyntaxKind.JSDocSignature; + } + export interface JSDocPropertyLikeTag extends JSDocTag, Declaration { parent: JSDoc; name: EntityName;