Skip to content

Commit 38167bc

Browse files
committed
syntax fix
1 parent 6bda0cc commit 38167bc

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

src/compiler/parser.ts

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -3580,11 +3580,11 @@ namespace ts {
35803580
let diagnostic: DiagnosticMessage;
35813581
if (isFunctionTypeNode(type)) {
35823582
diagnostic = isInUnionType
3583-
? Diagnostics.Function_type_notation_must_be_parenthesized_when_used_in_a_union_type;
3583+
? Diagnostics.Function_type_notation_must_be_parenthesized_when_used_in_a_union_type
35843584
: Diagnostics.Function_type_notation_must_be_parenthesized_when_used_in_an_intersection_type;
35853585
}
35863586
else {
3587-
diagnostic = isInUnionType ?
3587+
diagnostic = isInUnionType
35883588
? Diagnostics.Constructor_type_notation_must_be_parenthesized_when_used_in_a_union_type
35893589
: Diagnostics.Constructor_type_notation_must_be_parenthesized_when_used_in_an_intersection_type;
35903590

@@ -3602,7 +3602,7 @@ namespace ts {
36023602
): TypeNode {
36033603
const pos = getNodePos();
36043604
const hasLeadingOperator = parseOptional(operator);
3605-
let type = hasLeadingOperator && parseFunctionOrConstructorTypeToError(operator === SyntaxKind.BarToken)
3605+
let type = hasLeadingOperator && parseFunctionOrConstructorTypeToError(operator === SyntaxKind.BarToken)
36063606
|| parseConstituentType();
36073607
if (token() === operator || hasLeadingOperator) {
36083608
const types = [type];

0 commit comments

Comments
 (0)