aboutsummaryrefslogtreecommitdiff
path: root/llvm/lib/Object/COFFImportFile.cpp
diff options
context:
space:
mode:
authorRahul Joshi <rjoshi@nvidia.com>2024-08-16 09:26:57 -0700
committerGitHub <noreply@github.com>2024-08-16 09:26:57 -0700
commitddda37a6c72f0d2fb315d53043ed5e7a39eddfe0 (patch)
treed850e7c07b9da0a232bab4f2501d93ca2df0b077 /llvm/lib/Object/COFFImportFile.cpp
parent97f0ab71c002e8a14142be3a117b3091ab75c552 (diff)
downloadllvm-ddda37a6c72f0d2fb315d53043ed5e7a39eddfe0.zip
llvm-ddda37a6c72f0d2fb315d53043ed5e7a39eddfe0.tar.gz
llvm-ddda37a6c72f0d2fb315d53043ed5e7a39eddfe0.tar.bz2
[TableGen] Refactor Intrinsic handling in TableGen (#103980)
CodeGenIntrinsic changes: - Use `const` Record pointers, and `StringRef` when possible. - Default initialize several fields with their definition instead of in the constructor. - Simplify various string checks in the constructor using StringRef starts_with()/ends_with() functions. - Eliminate first argument to `setDefaultProperties` and use `TheDef` class member instead. IntrinsicEmitter changes: - Emit `namespace llvm::Intrinsic` instead of nested namespaces. - End generated comments with a . - Use range based for loops, and early continue within loops. - Emit `static constexpr` instead of `static const` for arrays. - Change `compareFnAttributes` to use std::tie() to compare intrinsic attributes and return a default value when all attributes are equal. STLExtras: - Add std::replace wrapper which takes a range.
Diffstat (limited to 'llvm/lib/Object/COFFImportFile.cpp')
-rw-r--r--llvm/lib/Object/COFFImportFile.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/llvm/lib/Object/COFFImportFile.cpp b/llvm/lib/Object/COFFImportFile.cpp
index e67b024..cc0a5da 100644
--- a/llvm/lib/Object/COFFImportFile.cpp
+++ b/llvm/lib/Object/COFFImportFile.cpp
@@ -705,7 +705,7 @@ Error writeImportLibrary(StringRef ImportName, StringRef Path,
Name = std::string(SymbolName);
} else {
Expected<std::string> ReplacedName =
- replace(SymbolName, E.Name, E.ExtName);
+ object::replace(SymbolName, E.Name, E.ExtName);
if (!ReplacedName)
return ReplacedName.takeError();
Name.swap(*ReplacedName);