De-virtualize getPreviousDecl() and getMostRecentDecl() when we know

we have a redeclarable type, and only use the new virtual versions
(getPreviousDeclImpl() and getMostRecentDeclImpl()) when we don't have
that type information. This keeps us from penalizing users with strict
type information (and is the moral equivalent of a "final" method).

Plus, settle on the names getPreviousDecl() and getMostRecentDecl()
throughout.

llvm-svn: 148187
This commit is contained in:
Douglas Gregor
2012-01-14 16:38:05 +00:00
parent b009517ad4
commit ec9fd13c77
25 changed files with 258 additions and 249 deletions

View File

@@ -1054,7 +1054,7 @@ CodeGenModule::GetOrCreateLLVMFunction(StringRef MangledName,
break;
}
}
FD = FD->getPreviousDeclaration();
FD = FD->getPreviousDecl();
} while (FD);
}