3
0
Fork 0
mirror of https://github.com/Z3Prover/z3 synced 2025-10-01 05:29:28 +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

@ -44,14 +44,14 @@ public:
m_exponent(0) {
}
void swap(mpff & other) {
void swap(mpff & 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;
std::swap(m_exponent, other.m_exponent);
}
};
inline void swap(mpff & m1, mpff & m2) { m1.swap(m2); }
inline void swap(mpff & m1, mpff & m2) noexcept { m1.swap(m2); }
class mpz;
class mpq;
@ -316,7 +316,7 @@ public:
*/
static void abs(mpff & a) { a.m_sign = 0; }
static void swap(mpff & a, mpff & b) { a.swap(b); }
static void swap(mpff & a, mpff & b) noexcept { a.swap(b); }
/**
\brief c <- a + b