[llvm] 6e55370 - Hide some implementation details so they can't cause ODR conflicts. NFC.
Benjamin Kramer via llvm-commits
llvm-commits at lists.llvm.org
Fri Jul 14 06:56:01 PDT 2023
Author: Benjamin Kramer
Date: 2023-07-14T15:54:04+02:00
New Revision: 6e55370b81aff8943f4de183699f18d9d7972174
URL: https://github.com/llvm/llvm-project/commit/6e55370b81aff8943f4de183699f18d9d7972174
DIFF: https://github.com/llvm/llvm-project/commit/6e55370b81aff8943f4de183699f18d9d7972174.diff
LOG: Hide some implementation details so they can't cause ODR conflicts. NFC.
Added:
Modified:
llvm/lib/TextAPI/TextStubV5.cpp
llvm/lib/Transforms/IPO/MemProfContextDisambiguation.cpp
Removed:
################################################################################
diff --git a/llvm/lib/TextAPI/TextStubV5.cpp b/llvm/lib/TextAPI/TextStubV5.cpp
index ade4c867fa49d4..5b3d69b8d94abb 100644
--- a/llvm/lib/TextAPI/TextStubV5.cpp
+++ b/llvm/lib/TextAPI/TextStubV5.cpp
@@ -72,6 +72,7 @@ using namespace llvm;
using namespace llvm::json;
using namespace llvm::MachO;
+namespace {
struct JSONSymbol {
SymbolKind Kind;
std::string Name;
@@ -697,6 +698,7 @@ Expected<std::vector<IFPtr>> getInlinedLibs(const Object *File) {
}
} // namespace StubParser
+} // namespace
Expected<std::unique_ptr<InterfaceFile>>
MachO::getInterfaceFileFromJSON(StringRef JSON) {
diff --git a/llvm/lib/Transforms/IPO/MemProfContextDisambiguation.cpp b/llvm/lib/Transforms/IPO/MemProfContextDisambiguation.cpp
index db87b3d57804c0..f835fb26fcb8f5 100644
--- a/llvm/lib/Transforms/IPO/MemProfContextDisambiguation.cpp
+++ b/llvm/lib/Transforms/IPO/MemProfContextDisambiguation.cpp
@@ -110,6 +110,7 @@ cl::opt<bool> SupportsHotColdNew(
"supports-hot-cold-new", cl::init(false), cl::Hidden,
cl::desc("Linking with hot/cold operator new interfaces"));
+namespace {
/// CRTP base for graphs built from either IR or ThinLTO summary index.
///
/// The graph represents the call contexts in all memprof metadata on allocation
@@ -628,6 +629,7 @@ class IndexCallsiteContextGraph
const ModuleSummaryIndex &Index;
};
+} // namespace
namespace llvm {
template <>
More information about the llvm-commits
mailing list