[mlir] Use StringRef::{starts,ends}_with (NFC)

This patch replaces uses of StringRef::{starts,ends}with with
StringRef::{starts,ends}_with for consistency with
std::{string,string_view}::{starts,ends}_with in C++20.

I'm planning to deprecate and eventually remove
StringRef::{starts,ends}with.
This commit is contained in:
Kazu Hirata
2023-12-13 22:58:30 -08:00
parent 5c9d82de6b
commit 88d319a29f
27 changed files with 36 additions and 34 deletions

View File

@@ -2564,7 +2564,7 @@ BytecodeReader::finalize(function_ref<bool(Operation *)> shouldMaterialize) {
}
bool mlir::isBytecode(llvm::MemoryBufferRef buffer) {
return buffer.getBuffer().startswith("ML\xefR");
return buffer.getBuffer().starts_with("ML\xefR");
}
/// Read the bytecode from the provided memory buffer reference.