From ae837e385b3a817f42b2d28a6f0887e09297d9a7 Mon Sep 17 00:00:00 2001 From: colbysparks Date: Mon, 29 Jul 2024 17:37:56 -0700 Subject: [PATCH] Delete assignment operator which modifies const field --- Rx/v2/src/rxcpp/rx-notification.hpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/Rx/v2/src/rxcpp/rx-notification.hpp b/Rx/v2/src/rxcpp/rx-notification.hpp index 330ddb924..6a24f0236 100644 --- a/Rx/v2/src/rxcpp/rx-notification.hpp +++ b/Rx/v2/src/rxcpp/rx-notification.hpp @@ -155,7 +155,7 @@ struct notification } on_error_notification(const on_error_notification& o) : ep(o.ep) {} on_error_notification(const on_error_notification&& o) : ep(std::move(o.ep)) {} - on_error_notification& operator=(on_error_notification o) { ep = std::move(o.ep); return *this; } + on_error_notification& operator=(on_error_notification o) RXCPP_DELETE; void out(std::ostream& os) const override { os << "on_error("; os << rxu::what(ep); @@ -274,7 +274,7 @@ std::ostream& operator<< (std::ostream& out, const recorded& r) { out << "@" << r.time() << "-" << r.value(); return out; } - + } namespace rxn=notifications;