[llvm] 444320a - [llvm-remarkutil] Make tryParseRemarksFromInputFile static

Jessica Paquette via llvm-commits llvm-commits at lists.llvm.org
Tue Sep 13 10:23:26 PDT 2022


Author: Jessica Paquette
Date: 2022-09-13T10:19:41-07:00
New Revision: 444320ab48f247bb1d37e08d0ccd5eb8033de645

URL: https://github.com/llvm/llvm-project/commit/444320ab48f247bb1d37e08d0ccd5eb8033de645
DIFF: https://github.com/llvm/llvm-project/commit/444320ab48f247bb1d37e08d0ccd5eb8033de645.diff

LOG: [llvm-remarkutil] Make tryParseRemarksFromInputFile static

All the functions in this file should be static to avoid ODR violations.

Added: 
    

Modified: 
    llvm/tools/llvm-remarkutil/RemarkUtil.cpp

Removed: 
    


################################################################################
diff  --git a/llvm/tools/llvm-remarkutil/RemarkUtil.cpp b/llvm/tools/llvm-remarkutil/RemarkUtil.cpp
index cc6edc7f2b6c1..09ba70c633cf6 100644
--- a/llvm/tools/llvm-remarkutil/RemarkUtil.cpp
+++ b/llvm/tools/llvm-remarkutil/RemarkUtil.cpp
@@ -80,7 +80,7 @@ getInputMemoryBuffer(StringRef InputFileName) {
 /// \p [out] StrTab - A string table populated for later remark serialization.
 /// \returns Error::success() if all remarks were successfully parsed, and an
 /// Error otherwise.
-Error tryParseRemarksFromInputFile(
+static Error tryParseRemarksFromInputFile(
     StringRef InputFileName, Format InputFormat,
     std::vector<std::unique_ptr<Remark>> &ParsedRemarks, StringTable &StrTab) {
   auto MaybeBuf = getInputMemoryBuffer(InputFileName);


        


More information about the llvm-commits mailing list