Skip to content

Commit f3b731f

Browse files
Fix some clang-tidy suggested issues 2
1 parent a6007db commit f3b731f

File tree

2 files changed

+5
-5
lines changed

2 files changed

+5
-5
lines changed

lib/Interpreter/CppInterOp.cpp

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3473,10 +3473,10 @@ namespace Cpp {
34733473

34743474
// Lazy materialization unit class helper
34753475
class AutoloadLibraryMU : public llvm::orc::MaterializationUnit {
3476-
const std::string lib;
3476+
std::string lib;
34773477
llvm::orc::SymbolNameVector syms;
34783478
public:
3479-
AutoloadLibraryMU(const std::string Library, const llvm::orc::SymbolNameVector &Symbols)
3479+
AutoloadLibraryMU(const std::string& Library, const llvm::orc::SymbolNameVector &Symbols)
34803480
: MaterializationUnit({getSymbolFlagsMap(Symbols), nullptr}), lib(Library), syms(Symbols) {}
34813481

34823482
[[nodiscard]] StringRef getName() const override {

lib/Interpreter/DynamicLibraryManager.cpp

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -392,9 +392,9 @@ namespace Cpp {
392392
return;
393393

394394
DyLibHandle dyLibHandle = nullptr;
395-
for (DyLibs::const_iterator I = m_DyLibs.begin(), E = m_DyLibs.end(); I != E; ++I) {
396-
if (I->second == canonicalLoadedLib) {
397-
dyLibHandle = I->first;
395+
for (const auto& dylib : m_DyLibs) {
396+
if (dylib.second == canonicalLoadedLib) {
397+
dyLibHandle = dylib.first;
398398
break;
399399
}
400400
}

0 commit comments

Comments
 (0)