3
0
Fork 0
mirror of https://github.com/Z3Prover/z3 synced 2025-06-27 00:18:45 +00:00

Use noexcept more. (#7058)

This commit is contained in:
Bruce Mitchener 2023-12-16 19:14:53 +07:00 committed by GitHub
parent b44ab2f620
commit 50e0fd3ba6
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
69 changed files with 97 additions and 112 deletions

View file

@ -38,13 +38,13 @@ public:
m_sig_idx(0) {
}
void swap(mpfx & other) {
void swap(mpfx & other) noexcept {
unsigned sign = m_sign; m_sign = other.m_sign; other.m_sign = sign;
unsigned sig_idx = m_sig_idx; m_sig_idx = other.m_sig_idx; other.m_sig_idx = sig_idx;
}
};
inline void swap(mpfx & m1, mpfx & m2) { m1.swap(m2); }
inline void swap(mpfx & m1, mpfx & m2) noexcept { m1.swap(m2); }
class mpz;
class mpq;
@ -228,7 +228,7 @@ public:
*/
static void abs(mpfx & a) { a.m_sign = 0; }
static void swap(mpfx & a, mpfx & b) { a.swap(b); }
static void swap(mpfx & a, mpfx & b) noexcept { a.swap(b); }
/**
\brief c <- a + b