aboutsummaryrefslogtreecommitdiffstats
path: root/sources/shiboken6/tests/libsample/oddbool.h
diff options
context:
space:
mode:
Diffstat (limited to 'sources/shiboken6/tests/libsample/oddbool.h')
-rw-r--r--sources/shiboken6/tests/libsample/oddbool.h12
1 files changed, 7 insertions, 5 deletions
diff --git a/sources/shiboken6/tests/libsample/oddbool.h b/sources/shiboken6/tests/libsample/oddbool.h
index a64a05eb3..dd2d32604 100644
--- a/sources/shiboken6/tests/libsample/oddbool.h
+++ b/sources/shiboken6/tests/libsample/oddbool.h
@@ -16,7 +16,7 @@ class OddBool
{
public:
- inline explicit OddBool(bool b) : m_value(b) {}
+ inline explicit OddBool(bool b) noexcept : m_value(b) {}
bool value() const { return m_value; }
inline OddBool operator!() const { return OddBool(!m_value); }
@@ -35,9 +35,11 @@ inline bool operator!=(OddBool b1, OddBool b2) { return (!b1).value() != (!b2).v
class OddBoolUser
{
public:
- OddBoolUser() : m_oddbool(OddBool(false)) {}
- OddBoolUser(const OddBool& oddBool) : m_oddbool(oddBool) {}
- virtual ~OddBoolUser() {}
+ LIBMINIMAL_DEFAULT_COPY_MOVE(OddBoolUser)
+
+ OddBoolUser() noexcept : m_oddbool(OddBool(false)) {}
+ OddBoolUser(const OddBool &oddBool) : m_oddbool(oddBool) {}
+ virtual ~OddBoolUser() = default;
inline OddBool oddBool() { return m_oddbool; }
inline void setOddBool(OddBool oddBool) { m_oddbool = oddBool; }
@@ -52,7 +54,7 @@ public:
return invertedOddBool();
}
- static inline OddBool getOddBool(const OddBoolUser& oddBoolUser)
+ static inline OddBool getOddBool(const OddBoolUser &oddBoolUser)
{
return oddBoolUser.m_oddbool;
}