[llvm] [CGData] Use StringRef instead of const std::string (PR #118749)

via llvm-commits llvm-commits at lists.llvm.org
Wed Dec 4 22:52:17 PST 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 0629e9e352fa8a2204e6165c61ce617f7096778e b8d790bab4419e9f61670e45ec9c33716169cbdf --extensions h,cpp -- llvm/include/llvm/CGData/StableFunctionMap.h llvm/lib/CGData/StableFunctionMap.cpp
``````````

</details>

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

``````````diff
diff --git a/llvm/include/llvm/CGData/StableFunctionMap.h b/llvm/include/llvm/CGData/StableFunctionMap.h
index 06e4efb5ac..0635fcad62 100644
--- a/llvm/include/llvm/CGData/StableFunctionMap.h
+++ b/llvm/include/llvm/CGData/StableFunctionMap.h
@@ -39,8 +39,8 @@ struct StableFunction {
   /// A vector of pairs of IndexPair and operand hash which was skipped.
   IndexOperandHashVecType IndexOperandHashes;
 
-  StableFunction(stable_hash Hash, StringRef FunctionName,
-                 StringRef ModuleName, unsigned InstCount,
+  StableFunction(stable_hash Hash, StringRef FunctionName, StringRef ModuleName,
+                 unsigned InstCount,
                  IndexOperandHashVecType &&IndexOperandHashes)
       : Hash(Hash), FunctionName(FunctionName), ModuleName(ModuleName),
         InstCount(InstCount),

``````````

</details>


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


More information about the llvm-commits mailing list