From af7929664503a2398800767892d132a0667d42c7 Mon Sep 17 00:00:00 2001 From: Argyrios Kyrtzidis Date: Wed, 29 Jul 2009 23:39:52 +0000 Subject: Modify the Indexer class so that it can return the TranslationUnit that internal decls originated from. llvm-svn: 77534 --- clang/lib/Index/Entity.cpp | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'clang/lib/Index/Entity.cpp') diff --git a/clang/lib/Index/Entity.cpp b/clang/lib/Index/Entity.cpp index 85b4f2e1961..d33110074f2 100644 --- a/clang/lib/Index/Entity.cpp +++ b/clang/lib/Index/Entity.cpp @@ -59,11 +59,12 @@ Entity EntityGetter::VisitNamedDecl(NamedDecl *D) { return Entity(D); // FIXME: Only works for DeclarationNames that are identifiers. + // Treats other DeclarationNames as internal Decls for now.. DeclarationName Name = D->getDeclName(); if (!Name.isIdentifier()) - return Entity(); + return Entity(D); IdentifierInfo *II = Name.getAsIdentifierInfo(); if (!II) -- cgit v1.2.3