summaryrefslogtreecommitdiffstats
path: root/lib/Parse/ParseInit.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'lib/Parse/ParseInit.cpp')
-rw-r--r--lib/Parse/ParseInit.cpp6
1 files changed, 4 insertions, 2 deletions
diff --git a/lib/Parse/ParseInit.cpp b/lib/Parse/ParseInit.cpp
index 8536420..7fe9862 100644
--- a/lib/Parse/ParseInit.cpp
+++ b/lib/Parse/ParseInit.cpp
@@ -423,9 +423,11 @@ ExprResult Parser::ParseBraceInitializer() {
if (Tok.is(tok::ellipsis))
SubElt = Actions.ActOnPackExpansion(SubElt.get(), ConsumeToken());
-
+
+ SubElt = Actions.CorrectDelayedTyposInExpr(SubElt.get());
+
// If we couldn't parse the subelement, bail out.
- if (!SubElt.isInvalid()) {
+ if (SubElt.isUsable()) {
InitExprs.push_back(SubElt.get());
} else {
InitExprsOk = false;
OpenPOWER on IntegriCloud