File tree Expand file tree Collapse file tree 2 files changed +18
-1
lines changed Expand file tree Collapse file tree 2 files changed +18
-1
lines changed Original file line number Diff line number Diff line change @@ -713,6 +713,6 @@ namespace ts.NavigationBar {
713
713
// \r - Carriage Return
714
714
// \u2028 - Line separator
715
715
// \u2029 - Paragraph separator
716
- return text . replace ( / \\ ( \r ? \n | \r | \u2028 | \u2029 ) / g, "" ) ;
716
+ return text . replace ( / \\ ? ( \r ? \n | \r | \u2028 | \u2029 ) / g, "" ) ;
717
717
}
718
718
}
Original file line number Diff line number Diff line change 8
8
//// const a = ' ''line1\
9
9
//// line2';
10
10
//// }
11
+ ////
12
+ //// f(() => { }, `unterminated backtick 1
13
+ //// unterminated backtick 2
14
+ //// unterminated backtick 3
11
15
12
16
verify . navigationTree ( {
13
17
"text" : "<global>" ,
@@ -34,6 +38,10 @@ verify.navigationTree({
34
38
{
35
39
"text" : "f(`line1line2line3`) callback" ,
36
40
"kind" : "function"
41
+ } ,
42
+ {
43
+ "text" : "f(`unterminated backtick 1unterminated backtick 2unterminated backtick 3) callback" ,
44
+ "kind" : "function"
37
45
}
38
46
]
39
47
} ) ;
@@ -54,6 +62,10 @@ verify.navigationBar([
54
62
{
55
63
"text" : "f(`line1line2line3`) callback" ,
56
64
"kind" : "function"
65
+ } ,
66
+ {
67
+ "text" : "f(`unterminated backtick 1unterminated backtick 2unterminated backtick 3) callback" ,
68
+ "kind" : "function"
57
69
}
58
70
]
59
71
} ,
@@ -81,5 +93,10 @@ verify.navigationBar([
81
93
"text" : "f(`line1line2line3`) callback" ,
82
94
"kind" : "function" ,
83
95
"indent" : 1
96
+ } ,
97
+ {
98
+ "text" : "f(`unterminated backtick 1unterminated backtick 2unterminated backtick 3) callback" ,
99
+ "kind" : "function" ,
100
+ "indent" : 1
84
101
}
85
102
] ) ;
You can’t perform that action at this time.
0 commit comments