diff options
author | Hal Finkel <hfinkel@anl.gov> | 2014-10-20 17:32:04 +0000 |
---|---|---|
committer | Hal Finkel <hfinkel@anl.gov> | 2014-10-20 17:32:04 +0000 |
commit | a2be46b72ec868472a83660035af272983fb33ea (patch) | |
tree | 1a068c60dbdbe67cad6b571053942fb49fadc2d9 /lib/Sema/SemaDecl.cpp | |
parent | 1c8a21c701d6cf7b768a9c99974599543a57c9f9 (diff) |
Add RestrictQualifierLoc to DeclaratorChunk::FunctionTypeInfo
Clang supports __restrict__ as a function qualifier, but
DeclaratorChunk::FunctionTypeInfo lacked a field to track the qualifier's
source location (as we do with volatile, etc.). This was the subject of a FIXME
in GetFullTypeForDeclarator (in SemaType.cpp). This should also prove useful as
we add more warnings regarding questionable uses of the restrict qualifier.
There is no significant functional change (except for an improved source range
associated with the err_invalid_qualified_function_type diagnostic fixit
generated by GetFullTypeForDeclarator).
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@220215 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/Sema/SemaDecl.cpp')
-rw-r--r-- | lib/Sema/SemaDecl.cpp | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/lib/Sema/SemaDecl.cpp b/lib/Sema/SemaDecl.cpp index 31266355e5..1666551d51 100644 --- a/lib/Sema/SemaDecl.cpp +++ b/lib/Sema/SemaDecl.cpp @@ -10666,6 +10666,7 @@ NamedDecl *Sema::ImplicitlyDefineFunction(SourceLocation Loc, /*RefQualifierLoc=*/NoLoc, /*ConstQualifierLoc=*/NoLoc, /*VolatileQualifierLoc=*/NoLoc, + /*RestrictQualifierLoc=*/NoLoc, /*MutableLoc=*/NoLoc, EST_None, /*ESpecLoc=*/NoLoc, |