File tree Expand file tree Collapse file tree 2 files changed +17
-0
lines changed Expand file tree Collapse file tree 2 files changed +17
-0
lines changed Original file line number Diff line number Diff line change @@ -363,6 +363,8 @@ namespace ts.JsDoc {
363
363
// want to give back a JSDoc template for the 'b' or 'c' in 'namespace a.b.c { }'.
364
364
return commentOwner . parent . kind === SyntaxKind . ModuleDeclaration ? undefined : { commentOwner } ;
365
365
366
+ case SyntaxKind . ExpressionStatement :
367
+ return getCommentOwnerInfoWorker ( ( commentOwner as ExpressionStatement ) . expression ) ;
366
368
case SyntaxKind . BinaryExpression : {
367
369
const be = commentOwner as BinaryExpression ;
368
370
if ( getAssignmentDeclarationKind ( be ) === AssignmentDeclarationKind . None ) {
Original file line number Diff line number Diff line change
1
+ /// <reference path='fourslash.ts' />
2
+
3
+ // @allowJs : true
4
+ // @checkJs : true
5
+
6
+ // @Filename : index.js
7
+ //// /** /**/ */
8
+ //// exports.foo = (a) => {};
9
+
10
+
11
+ verify . docCommentTemplateAt ( "" , 8 ,
12
+ `/**
13
+ *
14
+ * @param {any} a
15
+ */` ) ;
You can’t perform that action at this time.
0 commit comments