[llvm] RISCVAsmParser: Make diagnostics more conventional (PR #92024)

via llvm-commits llvm-commits at lists.llvm.org
Mon May 13 13:33:11 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 c3028a230557405b0f10bdd7d450f7f92747bbe3 34678188b45ab18b911fdf50e4cffdec946022a9 -- llvm/lib/Target/RISCV/AsmParser/RISCVAsmParser.cpp
``````````

</details>

<details>
<summary>
View the diff from clang-format here.
</summary>

``````````diff
diff --git a/llvm/lib/Target/RISCV/AsmParser/RISCVAsmParser.cpp b/llvm/lib/Target/RISCV/AsmParser/RISCVAsmParser.cpp
index d2a23ce6a6..7da1b7e360 100644
--- a/llvm/lib/Target/RISCV/AsmParser/RISCVAsmParser.cpp
+++ b/llvm/lib/Target/RISCV/AsmParser/RISCVAsmParser.cpp
@@ -2866,10 +2866,10 @@ bool RISCVAsmParser::parseDirectiveOption() {
         for (auto &Feature : RISCVFeatureKV) {
           if (getSTI().hasFeature(Feature.Value) &&
               Feature.Implies.test(Ext->Value))
-            return Error(Loc,
-                         Twine("can't disable ") + Ext->Key + " extension; " +
-                             Feature.Key + " extension requires " + Ext->Key +
-                             " extension");
+            return Error(Loc, Twine("can't disable ") + Ext->Key +
+                                  " extension; " + Feature.Key +
+                                  " extension requires " + Ext->Key +
+                                  " extension");
         }
 
         clearFeatureBits(Ext->Value, Ext->Key);

``````````

</details>


https://github.com/llvm/llvm-project/pull/92024


More information about the llvm-commits mailing list