summaryrefslogtreecommitdiffstats
path: root/clang
diff options
context:
space:
mode:
authorJohn McCall <rjmccall@apple.com>2010-03-11 09:33:17 +0000
committerJohn McCall <rjmccall@apple.com>2010-03-11 09:33:17 +0000
commit45d878b0f0f50664ea93a905021f094142a07243 (patch)
tree1f0505c408df189532cf1b1ec2fc8b76cd13a068 /clang
parent58f10c3380640962d251db70ac876e5ea7336c59 (diff)
downloadbcm5719-llvm-45d878b0f0f50664ea93a905021f094142a07243.tar.gz
bcm5719-llvm-45d878b0f0f50664ea93a905021f094142a07243.zip
Fix a self-host problem caused by this over-eager assertion. I'm not sure
there's a good equivalent that's actually true, unfortunately. llvm-svn: 98253
Diffstat (limited to 'clang')
-rw-r--r--clang/lib/Sema/TreeTransform.h2
-rw-r--r--clang/test/SemaTemplate/instantiate-function-1.cpp6
2 files changed, 6 insertions, 2 deletions
diff --git a/clang/lib/Sema/TreeTransform.h b/clang/lib/Sema/TreeTransform.h
index 61091cdcc04..d6f3352266a 100644
--- a/clang/lib/Sema/TreeTransform.h
+++ b/clang/lib/Sema/TreeTransform.h
@@ -2569,8 +2569,6 @@ bool TreeTransform<Derived>::
ParmVarDecl *NewParm;
if (OldParm) {
- assert(OldParm->getTypeSourceInfo()->getType() == T->getArgType(i));
-
NewParm = getDerived().TransformFunctionTypeParam(OldParm);
if (!NewParm)
return true;
diff --git a/clang/test/SemaTemplate/instantiate-function-1.cpp b/clang/test/SemaTemplate/instantiate-function-1.cpp
index 7b4c53cfe0d..6e0d7115900 100644
--- a/clang/test/SemaTemplate/instantiate-function-1.cpp
+++ b/clang/test/SemaTemplate/instantiate-function-1.cpp
@@ -214,3 +214,9 @@ template<typename T> struct X;
template<typename T> struct Y : public X<T> {
Y& x() { return *this; }
};
+
+// Make sure our assertions don't get too uppity.
+namespace test0 {
+ template <class T> class A { void foo(T array[10]); };
+ template class A<int>;
+}
OpenPOWER on IntegriCloud