Preserve the new moduleID field
authorChris Lattner <sabre@nondot.org>
Tue, 22 Apr 2003 18:02:26 +0000 (18:02 +0000)
committerChris Lattner <sabre@nondot.org>
Tue, 22 Apr 2003 18:02:26 +0000 (18:02 +0000)
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@5835 91177308-0d34-0410-b5e6-96231b3b80d8

lib/Transforms/Utils/CloneModule.cpp

index 223e3fd88cd0f95039cde5b395ae26474205651d..116ae0d4f3f280e2a17f5d95bde31be9f96dd35d 100644 (file)
@@ -18,7 +18,7 @@
 ///
 Module *CloneModule(const Module *M) {
   // First off, we need to create the new module...
-  Module *New = new Module();
+  Module *New = new Module(M->getModuleIdentifier());
 
   // Create the value map that maps things from the old module over to the new
   // module.