From 398444e67635c158a20301d1a32a1c45bfdd4056 Mon Sep 17 00:00:00 2001 From: Lioncash Date: Sun, 22 Jul 2018 01:23:29 -0400 Subject: file_util, vfs: Use std::string_view where applicable Avoids unnecessary construction of std::string instances where applicable. --- src/core/file_sys/vfs_offset.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'src/core/file_sys/vfs_offset.cpp') diff --git a/src/core/file_sys/vfs_offset.cpp b/src/core/file_sys/vfs_offset.cpp index 217e02235..a40331cef 100644 --- a/src/core/file_sys/vfs_offset.cpp +++ b/src/core/file_sys/vfs_offset.cpp @@ -80,7 +80,7 @@ size_t OffsetVfsFile::WriteBytes(const std::vector& data, size_t r_offset) { return file->Write(data.data(), TrimToFit(data.size(), r_offset), offset + r_offset); } -bool OffsetVfsFile::Rename(const std::string& name) { +bool OffsetVfsFile::Rename(std::string_view name) { return file->Rename(name); } -- cgit v1.2.3