diff options
author | Dominick Allen <djallen@librehumanitas.org> | 2024-10-03 08:07:05 -0500 |
---|---|---|
committer | Dominick Allen <djallen@librehumanitas.org> | 2024-10-03 08:07:05 -0500 |
commit | e420eca2b244c303af51534ab09632045a186b21 (patch) | |
tree | ba4ec2d6863b716672f35898266516b58c727aa9 /source/fud_c_file.cpp | |
parent | 97bbafb762defc01abc38834b70a7e8f20d654f5 (diff) |
Cleanup from clang-tidy.
Diffstat (limited to 'source/fud_c_file.cpp')
-rw-r--r-- | source/fud_c_file.cpp | 26 |
1 files changed, 10 insertions, 16 deletions
diff --git a/source/fud_c_file.cpp b/source/fud_c_file.cpp index e2e71bf..3961042 100644 --- a/source/fud_c_file.cpp +++ b/source/fud_c_file.cpp @@ -34,12 +34,9 @@ CBinaryFile::CBinaryFile(const String& filename, CFileMode mode, const String& e { } -CBinaryFile::CBinaryFile(CBinaryFile&& rhs) : - m_filename{std::move(rhs.m_filename)}, - m_extraFlags{std::move(rhs.m_extraFlags)}, - m_mode{std::move(rhs.m_mode)}, - m_modeFlags{std::move(rhs.m_modeFlags)}, - m_file{rhs.m_file} +CBinaryFile::CBinaryFile(CBinaryFile&& rhs) noexcept : + m_filename{std::move(rhs.m_filename)}, m_extraFlags{std::move(rhs.m_extraFlags)}, m_mode{std::move(rhs.m_mode)}, + m_modeFlags{rhs.m_modeFlags}, m_file{rhs.m_file} { } @@ -47,14 +44,14 @@ CBinaryFile::~CBinaryFile() { close(); } -CBinaryFile& CBinaryFile::operator=(CBinaryFile&& rhs) +CBinaryFile& CBinaryFile::operator=(CBinaryFile&& rhs) noexcept { close(); m_filename = std::move(rhs.m_filename); m_extraFlags = std::move(rhs.m_extraFlags); m_mode = std::move(rhs.m_mode); - m_modeFlags = std::move(rhs.m_modeFlags); + m_modeFlags = rhs.m_modeFlags; m_file = rhs.m_file; return *this; @@ -75,12 +72,9 @@ CTextFile::CTextFile(const String& filename, CFileMode mode, const String& extra { } -CTextFile::CTextFile(CTextFile&& rhs) : - m_filename{std::move(rhs.m_filename)}, - m_extraFlags{std::move(rhs.m_extraFlags)}, - m_mode{std::move(rhs.m_mode)}, - m_modeFlags{std::move(rhs.m_modeFlags)}, - m_file{rhs.m_file} +CTextFile::CTextFile(CTextFile&& rhs) noexcept : + m_filename{std::move(rhs.m_filename)}, m_extraFlags{std::move(rhs.m_extraFlags)}, m_mode{std::move(rhs.m_mode)}, + m_modeFlags{rhs.m_modeFlags}, m_file{rhs.m_file} { } @@ -88,14 +82,14 @@ CTextFile::~CTextFile() { close(); } -CTextFile& CTextFile::operator=(CTextFile&& rhs) +CTextFile& CTextFile::operator=(CTextFile&& rhs) noexcept { close(); m_filename = std::move(rhs.m_filename); m_extraFlags = std::move(rhs.m_extraFlags); m_mode = std::move(rhs.m_mode); - m_modeFlags = std::move(rhs.m_modeFlags); + m_modeFlags = rhs.m_modeFlags; m_file = rhs.m_file; return *this; |