[PATCH] Preserve paramater attributes during template instantiation
Jordan Rose
jordan_rose at apple.com
Fri Mar 8 11:48:18 PST 2013
Use a FunctionProtoType::ExtProtoInfo in Sema::BuildFunctionType if one is available.
I'm not sure we actually need to keep the old overload of BuildFunctionType around; there aren't any callers anymore. What do you think? Should we just require ExtProtoInfo all the time?
Also, drop attributes in StripImplicitInstantiation (though since `ns_consumed` and friends are type-sensitive, it will refuse an explicit specialization without them anyway).
This patch depends on ArrayRef-ization of Sema::BuildFunctionType and ASTContext::getFunctionType, which I'm about to commit once it passes all the tests.
Hi doug.gregor, rsmith,
http://llvm-reviews.chandlerc.com/D474
CHANGE SINCE LAST DIFF
http://llvm-reviews.chandlerc.com/D474?vs=1135&id=1219#toc
Files:
include/clang/Sema/Sema.h
lib/Sema/SemaTemplate.cpp
lib/Sema/SemaTemplateDeduction.cpp
lib/Sema/SemaTemplateInstantiate.cpp
lib/Sema/SemaType.cpp
lib/Sema/TreeTransform.h
test/CodeGenObjCXX/arc-attrs.mm
test/SemaObjCXX/arc-nsconsumed-errors.mm
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D474.2.patch
Type: text/x-patch
Size: 11295 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/cfe-commits/attachments/20130308/85278401/attachment.bin>
More information about the cfe-commits
mailing list