diff --git a/src/sfizz/Voice.cpp b/src/sfizz/Voice.cpp index 7f5faadc..e57dd627 100644 --- a/src/sfizz/Voice.cpp +++ b/src/sfizz/Voice.cpp @@ -266,8 +266,7 @@ Voice::~Voice() } -Voice::Voice(Voice&& other) { - ASSERT(other.impl_); +Voice::Voice(Voice&& other) noexcept { impl_ = std::move(other.impl_); if (other.nextSisterVoice_ != &other) { @@ -287,8 +286,7 @@ Voice::Voice(Voice&& other) { } } -Voice& Voice::operator=(Voice&& other) { - ASSERT(other.impl_); +Voice& Voice::operator=(Voice&& other) noexcept { impl_ = std::move(other.impl_); if (other.nextSisterVoice_ != &other) { diff --git a/src/sfizz/Voice.h b/src/sfizz/Voice.h index c5e55bcb..2e79584a 100644 --- a/src/sfizz/Voice.h +++ b/src/sfizz/Voice.h @@ -37,8 +37,8 @@ public: ~Voice(); Voice(const Voice& other) = delete; Voice& operator=(const Voice& other) = delete; - Voice(Voice&& other); - Voice& operator=(Voice&& other); + Voice(Voice&& other) noexcept; + Voice& operator=(Voice&& other) noexcept; /** * @brief Get the unique identifier of this voice in a synth