diff options
author | Andrew Gozillon <andrew.gozillon@uws.ac.uk> | 2017-10-02 06:25:51 +0000 |
---|---|---|
committer | Andrew Gozillon <andrew.gozillon@uws.ac.uk> | 2017-10-02 06:25:51 +0000 |
commit | 572bbb075483b07084526bc30b180b743257ca5a (patch) | |
tree | 70b646fde30a35410f4ef93059e28b7725c2b078 /clang/lib/Sema/SemaTemplate.cpp | |
parent | d37625859a6a663c33390e6a15ad5eca46579bc3 (diff) | |
download | bcm5719-llvm-572bbb075483b07084526bc30b180b743257ca5a.tar.gz bcm5719-llvm-572bbb075483b07084526bc30b180b743257ca5a.zip |
Dependent Address Space Support
This patch relates to: https://reviews.llvm.org/D33666 This adds support
for template parameters to be passed to the address_space attribute.
The main goal is to add further flexibility to the attribute and allow
for it to be used easily with templates.
The main additions are a new type (DependentAddressSpaceType) alongside
its TypeLoc and its mangling. As well as the logic required to support
dependent address spaces which mainly resides in TreeTransform.h and
SemaType.cpp.
llvm-svn: 314649
Diffstat (limited to 'clang/lib/Sema/SemaTemplate.cpp')
-rw-r--r-- | clang/lib/Sema/SemaTemplate.cpp | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/clang/lib/Sema/SemaTemplate.cpp b/clang/lib/Sema/SemaTemplate.cpp index 050e18944a7..c621ba1323d 100644 --- a/clang/lib/Sema/SemaTemplate.cpp +++ b/clang/lib/Sema/SemaTemplate.cpp @@ -5125,6 +5125,11 @@ bool UnnamedLocalNoLinkageFinder::VisitDependentSizedExtVectorType( return Visit(T->getElementType()); } +bool UnnamedLocalNoLinkageFinder::VisitDependentAddressSpaceType( + const DependentAddressSpaceType *T) { + return Visit(T->getPointeeType()); +} + bool UnnamedLocalNoLinkageFinder::VisitVectorType(const VectorType* T) { return Visit(T->getElementType()); } |