diff options
Diffstat (limited to 'include')
-rw-r--r-- | include/ilist.h | 7 | ||||
-rw-r--r-- | include/my_atomic_wrapper.h | 2 | ||||
-rw-r--r-- | include/my_counter.h | 2 | ||||
-rw-r--r-- | include/span.h | 2 |
4 files changed, 6 insertions, 7 deletions
diff --git a/include/ilist.h b/include/ilist.h index 6e7219937dd..f9afb5ec986 100644 --- a/include/ilist.h +++ b/include/ilist.h @@ -27,12 +27,11 @@ // Derive your class from this struct to insert to a linked list. template <class Tag= void> struct ilist_node { - ilist_node() noexcept #ifndef DBUG_OFF - : next(NULL), prev(NULL) + ilist_node() noexcept : next(NULL), prev(NULL) {} +#else + ilist_node() = default; #endif - { - } ilist_node(ilist_node *next, ilist_node *prev) noexcept : next(next), prev(prev) diff --git a/include/my_atomic_wrapper.h b/include/my_atomic_wrapper.h index c574fba4a8e..f5a4b8b80d3 100644 --- a/include/my_atomic_wrapper.h +++ b/include/my_atomic_wrapper.h @@ -39,7 +39,7 @@ public: Atomic_relaxed(const Atomic_relaxed<Type> &rhs) { m.store(rhs, std::memory_order_relaxed); } Atomic_relaxed(Type val) : m(val) {} - Atomic_relaxed() {} + Atomic_relaxed() = default; operator Type() const { return m.load(std::memory_order_relaxed); } Type operator=(const Type val) diff --git a/include/my_counter.h b/include/my_counter.h index c5cbe296df0..f85b8e80bd7 100644 --- a/include/my_counter.h +++ b/include/my_counter.h @@ -31,7 +31,7 @@ public: Atomic_counter(const Atomic_counter<Type> &rhs) { m_counter.store(rhs, std::memory_order_relaxed); } Atomic_counter(Type val): m_counter(val) {} - Atomic_counter() {} + Atomic_counter() = default; Type operator++(int) { return add(1); } Type operator--(int) { return sub(1); } diff --git a/include/span.h b/include/span.h index 0e8516933c6..4ea200f5494 100644 --- a/include/span.h +++ b/include/span.h @@ -81,7 +81,7 @@ public: span(const span &other) : data_(other.data_), size_(other.size_) {} - ~span(){}; + ~span() = default; span &operator=(const span &other) { |