Decend into DeclContexts in general.

This commit is contained in:
Vassil Vassilev 2014-08-08 17:07:22 +02:00 committed by sftnight
parent 7238b2eb7b
commit 561980e92d

View File

@ -19,6 +19,12 @@ namespace cling {
class DeclFixer : public DeclVisitor<DeclFixer> {
public:
void VisitDecl(Decl* D) {
if (DeclContext* DC = dyn_cast<DeclContext>(D))
for (auto Child : DC->decls())
Visit(Child);
}
void VisitEnumDecl(EnumDecl* ED) {
if (ED->isFixed()) {
StringRef str = ED->getAttr<AnnotateAttr>()->getAnnotation();