From 38250fc304ab66bf39613e6694bade2dbb4530b3 Mon Sep 17 00:00:00 2001 From: Nikolaj Bjorner Date: Thu, 29 Jul 2021 15:33:19 -0700 Subject: [PATCH] re-move #5442 --- src/api/c++/z3++.h | 10 +--------- 1 file changed, 1 insertion(+), 9 deletions(-) diff --git a/src/api/c++/z3++.h b/src/api/c++/z3++.h index 73330da89..72cd364c6 100644 --- a/src/api/c++/z3++.h +++ b/src/api/c++/z3++.h @@ -506,7 +506,7 @@ namespace z3 { public: ast(context & c):object(c), m_ast(0) {} ast(context & c, Z3_ast n):object(c), m_ast(n) { Z3_inc_ref(ctx(), m_ast); } - ast(ast const & s):object(s), m_ast(s.m_ast) { Z3_inc_ref(ctx(), m_ast); } + ast(ast const & s) :object(s), m_ast(s.m_ast) { Z3_inc_ref(ctx(), m_ast); } ast(ast && s) noexcept : object(std::forward(s)), m_ast(s.m_ast) { s.m_ast = nullptr; } ~ast() { if (m_ast) Z3_dec_ref(*m_ctx, m_ast); } operator Z3_ast() const { return m_ast; } @@ -519,14 +519,6 @@ namespace z3 { m_ast = s.m_ast; return *this; } - ast & operator=(ast && s) noexcept { - if (this != &s) { - object::operator=(std::forward(s)); - m_ast = s.m_ast; - s.m_ast = nullptr; - } - return *this; - } Z3_ast_kind kind() const { Z3_ast_kind r = Z3_get_ast_kind(ctx(), m_ast); check_error(); return r; } unsigned hash() const { unsigned r = Z3_get_ast_hash(ctx(), m_ast); check_error(); return r; } friend std::ostream & operator<<(std::ostream & out, ast const & n);