Skip to content

Commit adb60d5

Browse files
committed
codestyle
1 parent 2fea700 commit adb60d5

File tree

1 file changed

+4
-4
lines changed

1 file changed

+4
-4
lines changed

mlir/lib/Target/LLVMIR/ModuleTranslation.cpp

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -2042,10 +2042,10 @@ LogicalResult ModuleTranslation::createDependentLibrariesMetadata() {
20422042
auto *nmd =
20432043
llvmModule->getOrInsertNamedMetadata("llvm.dependent-libraries");
20442044
llvm::LLVMContext &ctx = llvmModule->getContext();
2045-
for (auto lib : cast<ArrayAttr>(dependentLibrariesAttr)) {
2046-
auto *md = llvm::MDNode::get(
2047-
ctx,
2048-
llvm::MDString::get(ctx, mlir::cast<StringAttr>(lib).getValue()));
2045+
for (auto libAttr :
2046+
cast<ArrayAttr>(dependentLibrariesAttr).getAsRange<StringAttr>()) {
2047+
auto *md =
2048+
llvm::MDNode::get(ctx, llvm::MDString::get(ctx, libAttr.getValue()));
20492049
nmd->addOperand(md);
20502050
}
20512051
}

0 commit comments

Comments
 (0)