Refactor CodeGenTypes out to CodeGenModule so it can be used for functions
and globals.

llvm-svn: 39661
diff --git a/clang/CodeGen/CodeGenModule.cpp b/clang/CodeGen/CodeGenModule.cpp
index 648e0ad..6ec9b79 100644
--- a/clang/CodeGen/CodeGenModule.cpp
+++ b/clang/CodeGen/CodeGenModule.cpp
@@ -13,11 +13,15 @@
 
 #include "CodeGenModule.h"
 #include "CodeGenFunction.h"
+#include "clang/AST/ASTContext.h"
 #include "clang/AST/Decl.h"
 using namespace clang;
 using namespace CodeGen;
 
 
+CodeGenModule::CodeGenModule(ASTContext &C, llvm::Module &M)
+  : Context(C), TheModule(M), Types(C.Target) {}
+
 void CodeGenModule::EmitFunction(FunctionDecl *FD) {
   // If this is not a prototype, emit the body.
   if (FD->getBody())