[lld] [LLD][COFF] Handle imported weak aliases consistently (PR #109105)
    via llvm-commits 
    llvm-commits at lists.llvm.org
       
    Wed Sep 18 02:06:02 PDT 2024
    
    
  
github-actions[bot] wrote:
<!--LLVM CODE FORMAT COMMENT: {clang-format}-->
:warning: C/C++ code formatter, clang-format found issues in your code. :warning:
<details>
<summary>
You can test this locally with the following command:
</summary>
``````````bash
git-clang-format --diff f8eceb45d0bbca092164efffc92f2e9d66b304a5 cf6ccff681827d2e38554cb66897e719a4248f04 --extensions cpp -- lld/COFF/SymbolTable.cpp
``````````
</details>
<details>
<summary>
View the diff from clang-format here.
</summary>
``````````diff
diff --git a/lld/COFF/SymbolTable.cpp b/lld/COFF/SymbolTable.cpp
index 6b96d8bbda..1488ad95d0 100644
--- a/lld/COFF/SymbolTable.cpp
+++ b/lld/COFF/SymbolTable.cpp
@@ -503,12 +503,12 @@ void SymbolTable::resolveRemainingUndefines() {
     if (name.starts_with("__imp_")) {
       Symbol *imp = find(name.substr(strlen("__imp_")));
       if (imp) {
-         // The unprefixed symbol might come later in symMap, so handle it now
-	 // so that the condition below can be appropriately applied.
-         auto *undef = dyn_cast<Undefined>(imp);
-         if (undef) {
-            undef->resolveWeakAlias();
-         }
+        // The unprefixed symbol might come later in symMap, so handle it now
+        // so that the condition below can be appropriately applied.
+        auto *undef = dyn_cast<Undefined>(imp);
+        if (undef) {
+          undef->resolveWeakAlias();
+        }
       }
       if (imp && isa<Defined>(imp)) {
         auto *d = cast<Defined>(imp);
``````````
</details>
https://github.com/llvm/llvm-project/pull/109105
    
    
More information about the llvm-commits
mailing list