diff --git a/lldb/include/lldb/Core/ModuleList.h b/lldb/include/lldb/Core/ModuleList.h index f03f79fb00ce..a736511bf302 100644 --- a/lldb/include/lldb/Core/ModuleList.h +++ b/lldb/include/lldb/Core/ModuleList.h @@ -15,6 +15,7 @@ #include "lldb/lldb-private.h" #include "lldb/Host/Mutex.h" +#include "lldb/Utility/Iterable.h" namespace lldb_private { @@ -577,6 +578,14 @@ protected: Notifier* m_notifier; +public: + typedef LockingAdaptedIterable ModuleIterable; + ModuleIterable + Modules() + { + return ModuleIterable(m_modules, GetMutex()); + } + }; } // namespace lldb_private