File tree 4 files changed +8
-16
lines changed
src/compiler/transformers 4 files changed +8
-16
lines changed Original file line number Diff line number Diff line change @@ -1510,8 +1510,7 @@ namespace ts {
1510
1510
break ;
1511
1511
1512
1512
default :
1513
- Debug . failBadSyntaxKind ( node ) ;
1514
- break ;
1513
+ return Debug . failBadSyntaxKind ( node ) ;
1515
1514
}
1516
1515
1517
1516
const captureNewTargetStatement = createVariableStatement (
Original file line number Diff line number Diff line change @@ -430,8 +430,7 @@ namespace ts {
430
430
return visitFunctionExpression ( < FunctionExpression > node ) ;
431
431
432
432
default :
433
- Debug . failBadSyntaxKind ( node ) ;
434
- return visitEachChild ( node , visitor , context ) ;
433
+ return Debug . failBadSyntaxKind ( node ) ;
435
434
}
436
435
}
437
436
Original file line number Diff line number Diff line change @@ -72,8 +72,7 @@ namespace ts {
72
72
return visitJsxFragment ( node , /*isChild*/ true ) ;
73
73
74
74
default :
75
- Debug . failBadSyntaxKind ( node ) ;
76
- return undefined ;
75
+ return Debug . failBadSyntaxKind ( node ) ;
77
76
}
78
77
}
79
78
@@ -182,7 +181,7 @@ namespace ts {
182
181
return visitJsxExpression ( node ) ;
183
182
}
184
183
else {
185
- Debug . failBadSyntaxKind ( node ) ;
184
+ return Debug . failBadSyntaxKind ( node ) ;
186
185
}
187
186
}
188
187
Original file line number Diff line number Diff line change @@ -324,8 +324,7 @@ namespace ts {
324
324
return node ;
325
325
326
326
default :
327
- Debug . failBadSyntaxKind ( node ) ;
328
- return undefined ;
327
+ return Debug . failBadSyntaxKind ( node ) ;
329
328
}
330
329
}
331
330
@@ -531,8 +530,7 @@ namespace ts {
531
530
return visitImportEqualsDeclaration ( < ImportEqualsDeclaration > node ) ;
532
531
533
532
default :
534
- Debug . failBadSyntaxKind ( node ) ;
535
- return visitEachChild ( node , visitor , context ) ;
533
+ return Debug . failBadSyntaxKind ( node ) ;
536
534
}
537
535
}
538
536
@@ -1870,10 +1868,8 @@ namespace ts {
1870
1868
return createIdentifier ( "Boolean" ) ;
1871
1869
1872
1870
default :
1873
- Debug . failBadSyntaxKind ( ( < LiteralTypeNode > node ) . literal ) ;
1874
- break ;
1871
+ return Debug . failBadSyntaxKind ( ( < LiteralTypeNode > node ) . literal ) ;
1875
1872
}
1876
- break ;
1877
1873
1878
1874
case SyntaxKind . NumberKeyword :
1879
1875
return createIdentifier ( "Number" ) ;
@@ -1900,8 +1896,7 @@ namespace ts {
1900
1896
break ;
1901
1897
1902
1898
default :
1903
- Debug . failBadSyntaxKind ( node ) ;
1904
- break ;
1899
+ return Debug . failBadSyntaxKind ( node ) ;
1905
1900
}
1906
1901
1907
1902
return createIdentifier ( "Object" ) ;
You can’t perform that action at this time.
0 commit comments