mirror of
https://github.com/Kitware/CMake.git
synced 2026-03-14 21:41:06 -05:00
String: Make swap method noexcept
There is no reason why it should not be `noexcept`. `std::swap` cannot have any exceptions or handle any.
This commit is contained in:
@@ -518,7 +518,7 @@ public:
|
||||
*this = std::move(s);
|
||||
}
|
||||
|
||||
void swap(String& other)
|
||||
void swap(String& other) noexcept
|
||||
{
|
||||
std::swap(this->string_, other.string_);
|
||||
std::swap(this->view_, other.view_);
|
||||
|
||||
Reference in New Issue
Block a user