summaryrefslogtreecommitdiffstats
path: root/clang/lib/Parse/Parser.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'clang/lib/Parse/Parser.cpp')
-rw-r--r--clang/lib/Parse/Parser.cpp5
1 files changed, 4 insertions, 1 deletions
diff --git a/clang/lib/Parse/Parser.cpp b/clang/lib/Parse/Parser.cpp
index 495d5e51dd5..a245ac2156b 100644
--- a/clang/lib/Parse/Parser.cpp
+++ b/clang/lib/Parse/Parser.cpp
@@ -423,7 +423,10 @@ Parser::DeclGroupPtrTy Parser::ParseExternalDeclaration() {
case tok::kw_export: // As in 'export template'
case tok::kw_static_assert:
// A function definition cannot start with a these keywords.
- return ParseDeclaration(Declarator::FileContext);
+ {
+ SourceLocation DeclEnd;
+ return ParseDeclaration(Declarator::FileContext, DeclEnd);
+ }
default:
// We can't tell whether this is a function-definition or declaration yet.
return ParseDeclarationOrFunctionDefinition();
OpenPOWER on IntegriCloud