Check if the two clang opaque type pointers are equal before doing anything more exhaustive comparison.



git-svn-id: https://llvm.org/svn/llvm-project/lldb/trunk@154181 91177308-0d34-0410-b5e6-96231b3b80d8
diff --git a/source/Symbol/ClangASTContext.cpp b/source/Symbol/ClangASTContext.cpp
index 88e18a5..03424ab 100644
--- a/source/Symbol/ClangASTContext.cpp
+++ b/source/Symbol/ClangASTContext.cpp
@@ -1045,6 +1045,9 @@
                                clang_type_t type2,
                                bool ignore_qualifiers)
 {
+    if (type1 == type2)
+        return true;
+
     QualType type1_qual = QualType::getFromOpaquePtr(type1);
     QualType type2_qual = QualType::getFromOpaquePtr(type2);