Make SymbolContexts iterable with the C++11 for (a : b) syntax using Sean’s AdaptedIterable.
llvm-svn: 198968
This commit is contained in:
parent
ea3ac27029
commit
c46e479d12
|
@ -17,6 +17,7 @@
|
|||
#include "lldb/Core/Address.h"
|
||||
#include "lldb/Core/Mangled.h"
|
||||
#include "lldb/Symbol/LineEntry.h"
|
||||
#include "lldb/Utility/Iterable.h"
|
||||
|
||||
namespace lldb_private {
|
||||
|
||||
|
@ -552,6 +553,14 @@ protected:
|
|||
// Member variables.
|
||||
//------------------------------------------------------------------
|
||||
collection m_symbol_contexts; ///< The list of symbol contexts.
|
||||
|
||||
public:
|
||||
typedef AdaptedIterable<collection, SymbolContext, vector_adapter> SymbolContextIterable;
|
||||
SymbolContextIterable
|
||||
SymbolContexts()
|
||||
{
|
||||
return SymbolContextIterable(m_symbol_contexts);
|
||||
}
|
||||
};
|
||||
|
||||
bool operator== (const SymbolContext& lhs, const SymbolContext& rhs);
|
||||
|
|
Loading…
Reference in New Issue