Skip to content

Commit 2101029

Browse files
authored
Merge pull request swiftlang#28906 from drodriguez/windows-explicit-parameter-order-evaluation
[MSVC] Evaluate parameters in the right order.
2 parents d0e5270 + fb30e9e commit 2101029

File tree

1 file changed

+3
-2
lines changed

1 file changed

+3
-2
lines changed

lib/Parse/ParseExpr.cpp

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2483,8 +2483,9 @@ parseClosureSignatureIfPresent(SourceRange &bracketRange,
24832483

24842484
SyntaxParsingContext CaptureCtx(SyntaxContext,
24852485
SyntaxKind::ClosureCaptureSignature);
2486-
bracketRange = SourceRange(consumeToken(tok::l_square),
2487-
consumeToken(tok::r_square));
2486+
SourceLoc lBracketLoc = consumeToken(tok::l_square);
2487+
SourceLoc rBracketLoc = consumeToken(tok::r_square);
2488+
bracketRange = SourceRange(lBracketLoc, rBracketLoc);
24882489
} else if (Tok.is(tok::l_square) && !peekToken().is(tok::r_square)) {
24892490
SyntaxParsingContext CaptureCtx(SyntaxContext,
24902491
SyntaxKind::ClosureCaptureSignature);

0 commit comments

Comments
 (0)