Added recursive name lookup logging with depth which is commented out and is currently only enabled when we blow the stack.
git-svn-id: https://llvm.org/svn/llvm-project/llvdb/trunk@119101 91177308-0d34-0410-b5e6-96231b3b80d8
diff --git a/source/Expression/ClangASTSource.cpp b/source/Expression/ClangASTSource.cpp
index aa69abf..330c1da 100644
--- a/source/Expression/ClangASTSource.cpp
+++ b/source/Expression/ClangASTSource.cpp
@@ -99,10 +99,14 @@
return DeclContext::lookup_result();
}
m_active_lookups.insert(uniqued_const_decl_name);
+// static uint32_t g_depth = 0;
+// ++g_depth;
+// printf("[%5u] FindExternalVisibleDeclsByName() \"%s\"\n", g_depth, uniqued_const_decl_name);
llvm::SmallVector<NamedDecl*, 4> name_decls;
NameSearchContext name_search_context(*this, name_decls, clang_decl_name, decl_ctx);
m_decl_map.GetDecls(name_search_context, const_decl_name);
DeclContext::lookup_result result (SetExternalVisibleDeclsForName (decl_ctx, clang_decl_name, name_decls));
+// --g_depth;
m_active_lookups.erase (uniqued_const_decl_name);
return result;
}