Author: Adrian Prantl
Date: 2019-12-10T16:11:10-08:00
New Revision: 2fb07b90dc1c2c08fe6fc69c9d569a1fc2c8a8e1

URL: 
https://github.com/llvm/llvm-project/commit/2fb07b90dc1c2c08fe6fc69c9d569a1fc2c8a8e1
DIFF: 
https://github.com/llvm/llvm-project/commit/2fb07b90dc1c2c08fe6fc69c9d569a1fc2c8a8e1.diff

LOG: Remove unsound caching in LanguageCategory

Analogous to https://reviews.llvm.org/D71233 it is not safe to cache
something that depends on the actual ValueObject in a cache then keys
only off the type name.

Differential Revision: https://reviews.llvm.org/D71297

Added: 
    

Modified: 
    lldb/source/DataFormatters/LanguageCategory.cpp

Removed: 
    


################################################################################
diff  --git a/lldb/source/DataFormatters/LanguageCategory.cpp 
b/lldb/source/DataFormatters/LanguageCategory.cpp
index 78237e18fb20..d4d8bb9cc8d6 100644
--- a/lldb/source/DataFormatters/LanguageCategory.cpp
+++ b/lldb/source/DataFormatters/LanguageCategory.cpp
@@ -110,10 +110,6 @@ bool LanguageCategory::GetHardcoded(FormatManager &fmt_mgr,
       break;
     }
   }
-  if (match_data.GetTypeForCache() &&
-      (!retval_sp || !retval_sp->NonCacheable())) {
-    m_format_cache.Set(match_data.GetTypeForCache(), retval_sp);
-  }
   return (bool)retval_sp;
 }
 


        
_______________________________________________
lldb-commits mailing list
lldb-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits

Reply via email to