diff options
author | Sebastian Redl <sebastian.redl@getdesigned.at> | 2009-10-25 17:03:50 +0000 |
---|---|---|
committer | Sebastian Redl <sebastian.redl@getdesigned.at> | 2009-10-25 17:03:50 +0000 |
commit | 9994a34f6cf842721ba7723edc0b9036229fe387 (patch) | |
tree | 3c68a7991a033f95c76d6997feba2c0cffee94a4 /lib/Frontend/ASTConsumers.cpp | |
parent | bbc1cc5757d0ef068bef583ee4eda108dece806c (diff) | |
download | clang-9994a34f6cf842721ba7723edc0b9036229fe387.tar.gz |
Audit the code for places where it is assumed that every base specifier refers to a RecordType. Add assertions or conditions as appropriate. This fixes another crash in the Apache stdlib vector.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@85055 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/Frontend/ASTConsumers.cpp')
-rw-r--r-- | lib/Frontend/ASTConsumers.cpp | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/lib/Frontend/ASTConsumers.cpp b/lib/Frontend/ASTConsumers.cpp index 446678ab6d..9a30f59465 100644 --- a/lib/Frontend/ASTConsumers.cpp +++ b/lib/Frontend/ASTConsumers.cpp @@ -452,6 +452,8 @@ class RecordLayoutDumper : public ASTConsumer { // Dump (non-virtual) bases for (CXXRecordDecl::base_class_const_iterator I = RD->bases_begin(), E = RD->bases_end(); I != E; ++I) { + assert(!I->getType()->isDependentType() && + "Cannot layout class with dependent bases."); if (I->isVirtual()) continue; |