Skip to content

Commit 0938749

Browse files
author
zhengbli
committed
Add test for jsdoc syntactic classification for function declaration
1 parent d24afc2 commit 0938749

File tree

1 file changed

+24
-0
lines changed

1 file changed

+24
-0
lines changed
Lines changed: 24 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,24 @@
1+
/// <reference path="fourslash.ts"/>
2+
3+
//// /** @param {number} p1 */
4+
//// function foo(p1) {}
5+
6+
var c = classification;
7+
verify.syntacticClassificationsAre(
8+
c.comment("/** "),
9+
c.punctuation("@"),
10+
c.docCommentTagName("param"),
11+
c.comment(" "),
12+
c.punctuation("{"),
13+
c.keyword("number"),
14+
c.punctuation("}"),
15+
c.comment(" "),
16+
c.parameterName("p1"),
17+
c.comment(" */"),
18+
c.keyword("function"),
19+
c.identifier("foo"),
20+
c.punctuation("("),
21+
c.parameterName("p1"),
22+
c.punctuation(")"),
23+
c.punctuation("{"),
24+
c.punctuation("}"));

0 commit comments

Comments
 (0)