diff options
| author | Eli Friedman <eli.friedman@gmail.com> | 2013-08-09 23:37:05 +0000 |
|---|---|---|
| committer | Eli Friedman <eli.friedman@gmail.com> | 2013-08-09 23:37:05 +0000 |
| commit | 8564139c0ec56fe8f9e692294f7ae103b609dbcb (patch) | |
| tree | fb4553078430b2dba3dfb57d27853877db414ae5 /clang/lib/AST | |
| parent | d6ce6cbdac5e0d433adb52499dc3ba9c59c4c5d1 (diff) | |
| download | bcm5719-llvm-8564139c0ec56fe8f9e692294f7ae103b609dbcb.tar.gz bcm5719-llvm-8564139c0ec56fe8f9e692294f7ae103b609dbcb.zip | |
Correctly profile CXXPseudoDestructorExprs.
CXXPseudoDestructorExprs may not contain a type. PR16852.
llvm-svn: 188123
Diffstat (limited to 'clang/lib/AST')
| -rw-r--r-- | clang/lib/AST/StmtProfile.cpp | 9 |
1 files changed, 8 insertions, 1 deletions
diff --git a/clang/lib/AST/StmtProfile.cpp b/clang/lib/AST/StmtProfile.cpp index a626f68aa58..eb93c1df0e2 100644 --- a/clang/lib/AST/StmtProfile.cpp +++ b/clang/lib/AST/StmtProfile.cpp @@ -910,7 +910,14 @@ StmtProfiler::VisitCXXPseudoDestructorExpr(const CXXPseudoDestructorExpr *S) { VisitExpr(S); ID.AddBoolean(S->isArrow()); VisitNestedNameSpecifier(S->getQualifier()); - VisitType(S->getDestroyedType()); + ID.AddBoolean(S->getScopeTypeInfo() != 0); + if (S->getScopeTypeInfo()) + VisitType(S->getScopeTypeInfo()->getType()); + ID.AddBoolean(S->getDestroyedTypeInfo() != 0); + if (S->getDestroyedTypeInfo()) + VisitType(S->getDestroyedType()); + else + ID.AddPointer(S->getDestroyedTypeIdentifier()); } void StmtProfiler::VisitOverloadExpr(const OverloadExpr *S) { |

