summaryrefslogtreecommitdiffstats
path: root/clang/lib
diff options
context:
space:
mode:
authorDavid Blaikie <dblaikie@gmail.com>2012-11-07 19:08:05 +0000
committerDavid Blaikie <dblaikie@gmail.com>2012-11-07 19:08:05 +0000
commit0da2fa35613e26474e760be3c62f79c382e4726c (patch)
treee70b1662ed67801b10afc3cadaf32554d32f236a /clang/lib
parent40f2d30987d2996d682c5972955767b1415ec637 (diff)
downloadbcm5719-llvm-0da2fa35613e26474e760be3c62f79c382e4726c.tar.gz
bcm5719-llvm-0da2fa35613e26474e760be3c62f79c382e4726c.zip
PR12713 - crash on invalid due to unmatched parens in decltype
llvm-svn: 167547
Diffstat (limited to 'clang/lib')
-rw-r--r--clang/lib/Parse/Parser.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/clang/lib/Parse/Parser.cpp b/clang/lib/Parse/Parser.cpp
index 7bf42201999..f4cdd619cef 100644
--- a/clang/lib/Parse/Parser.cpp
+++ b/clang/lib/Parse/Parser.cpp
@@ -1940,8 +1940,8 @@ bool BalancedDelimiterTracker::diagnoseMissingClose() {
}
P.Diag(P.Tok, DID);
P.Diag(LOpen, diag::note_matching) << LHSName;
- if (P.SkipUntil(Close))
- LClose = P.Tok.getLocation();
+ if (P.SkipUntil(Close, /*StopAtSemi*/ true, /*DontConsume*/ true))
+ LClose = P.ConsumeAnyToken();
return true;
}
OpenPOWER on IntegriCloud