diff --git a/clang/lib/Analysis/LifetimeTypeCategory.cpp b/clang/lib/Analysis/LifetimeTypeCategory.cpp index d20c365f7de0ec..1f550b83787dcf 100644 --- a/clang/lib/Analysis/LifetimeTypeCategory.cpp +++ b/clang/lib/Analysis/LifetimeTypeCategory.cpp @@ -119,19 +119,10 @@ static bool IsVectorBoolReference(const CXXRecordDecl *D) { // to look up the declarations (pointers) by names upfront and look up the // declarations instead of matching strings populated lazily. static Optional classifyStd(const Type *T) { - // MSVC: _Ptr_base is a base class of shared_ptr, and we only see - // _Ptr_base when calling get() on a shared_ptr. - static std::set StdOwners{"stack", "queue", "priority_queue", - "optional", "_Ptr_base", "array"}; - static std::set StdPointers{"basic_regex", "reference_wrapper"}; auto *Decl = T->getAsCXXRecordDecl(); if (!Decl || !Decl->isInStdNamespace() || !Decl->getIdentifier()) return {}; - if (StdOwners.count(Decl->getName())) - return TypeCategory::Owner; - if (StdPointers.count(Decl->getName())) - return TypeCategory::Pointer; if (IsVectorBoolReference(Decl)) return TypeCategory::Pointer;