Skip to content

Commit 94384ae

Browse files
authored
RuntimeLibcalls: Fix missing const on getLibcallNames (#143074)
This is made simpler by just returning the array ref instead of the fancy range.
1 parent 0d40574 commit 94384ae

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

llvm/include/llvm/IR/RuntimeLibcalls.h

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -81,9 +81,9 @@ struct RuntimeLibcallsInfo {
8181
return LibcallCallingConvs[Call];
8282
}
8383

84-
iterator_range<const char **> getLibcallNames() {
85-
return llvm::make_range(LibcallRoutineNames,
86-
LibcallRoutineNames + RTLIB::UNKNOWN_LIBCALL);
84+
ArrayRef<const char *> getLibcallNames() const {
85+
// Trim UNKNOWN_LIBCALL from the end
86+
return ArrayRef(LibcallRoutineNames).drop_back();
8787
}
8888

8989
private:

0 commit comments

Comments
 (0)