[llvm] 1d96e24 - [llvm-lib] Pass the right value of MingwDef to parseCOFFModuleDefinition

Martin Storsjö via llvm-commits llvm-commits at lists.llvm.org
Thu Jun 8 13:22:33 PDT 2023


Author: Martin Storsjö
Date: 2023-06-08T23:21:56+03:00
New Revision: 1d96e24dda2e3a925d5c28c00049edb0c2d6c743

URL: https://github.com/llvm/llvm-project/commit/1d96e24dda2e3a925d5c28c00049edb0c2d6c743
DIFF: https://github.com/llvm/llvm-project/commit/1d96e24dda2e3a925d5c28c00049edb0c2d6c743.diff

LOG: [llvm-lib] Pass the right value of MingwDef to parseCOFFModuleDefinition

In llvm-lib cases, the MinGW specific behaviours shouldn't be
enabled.

Not adding any tests to check the corner case behaviours, as this
simply was a mistake when this codepath was added in
395ec4458fb7fc700551f7017c0a395d68c55873 / D144765.

Differential Revision: https://reviews.llvm.org/D152362

Added: 
    

Modified: 
    llvm/lib/ToolDrivers/llvm-lib/LibDriver.cpp

Removed: 
    


################################################################################
diff  --git a/llvm/lib/ToolDrivers/llvm-lib/LibDriver.cpp b/llvm/lib/ToolDrivers/llvm-lib/LibDriver.cpp
index 17bdb1236efd4..747e4c5928eac 100644
--- a/llvm/lib/ToolDrivers/llvm-lib/LibDriver.cpp
+++ b/llvm/lib/ToolDrivers/llvm-lib/LibDriver.cpp
@@ -384,7 +384,7 @@ int llvm::libDriverMain(ArrayRef<const char *> ArgsArr) {
     }
 
     Expected<COFFModuleDefinition> Def =
-        parseCOFFModuleDefinition(*MB, LibMachine, true);
+        parseCOFFModuleDefinition(*MB, LibMachine, /*MingwDef=*/false);
 
     if (!Def) {
       llvm::errs() << "error parsing definition\n"


        


More information about the llvm-commits mailing list