[Lldb-commits] [lldb] [lldb] Replace PathMappingList::GetPathsAtIndex with thread-safe alternative (PR #147396)

Alex Langford via lldb-commits lldb-commits at lists.llvm.org
Tue Jul 8 10:59:08 PDT 2025


================
@@ -61,8 +61,10 @@ class PathMappingList {
     return m_pairs.size();
   }
 
-  bool GetPathsAtIndex(uint32_t idx, ConstString &path,
-                       ConstString &new_path) const;
+  /// Invokes callback for each pair of paths in the list. The callback can
+  /// return false to immediately stop iteration.
+  void ForEach(std::function<bool(size_t, llvm::StringRef, llvm::StringRef)>
----------------
bulbazord wrote:

Only used in one place. I'll look at `LockingAdaptedIterable` and see how bad it is.

https://github.com/llvm/llvm-project/pull/147396


More information about the lldb-commits mailing list