Move key functions to a separate map.
llvm-svn: 90745
diff --git a/clang/lib/CodeGen/CGVtable.cpp b/clang/lib/CodeGen/CGVtable.cpp
index 6fda6a4..d227a5e 100644
--- a/clang/lib/CodeGen/CGVtable.cpp
+++ b/clang/lib/CodeGen/CGVtable.cpp
@@ -1433,10 +1433,8 @@
if (!RD->isDynamicClass())
return;
- const ASTRecordLayout &Layout = CGM.getContext().getASTRecordLayout(RD);
-
// Get the key function.
- const CXXMethodDecl *KeyFunction = Layout.getKeyFunction();
+ const CXXMethodDecl *KeyFunction = CGM.getContext().getKeyFunction(RD);
if (KeyFunction) {
// We don't have the right key function.