From f0cccbe3285c039553e1fd8b5a5c7830d6087974 Mon Sep 17 00:00:00 2001 From: Steven Le Rouzic Date: Thu, 6 Mar 2025 22:56:56 +0100 Subject: Replace ASL_MOVE, ASL_FWD, and ASL_FWD_LIKE by their std:: equivalent This is because some compiler stuff and diagnostics tools rely on those symboles being what they are. --- asl/containers/buffer.hpp | 24 ++++++++++++------------ 1 file changed, 12 insertions(+), 12 deletions(-) (limited to 'asl/containers/buffer.hpp') diff --git a/asl/containers/buffer.hpp b/asl/containers/buffer.hpp index 8bdb63e..386b52a 100644 --- a/asl/containers/buffer.hpp +++ b/asl/containers/buffer.hpp @@ -170,7 +170,7 @@ private: if (assign) { - m_allocator = ASL_MOVE(other.m_allocator); + m_allocator = std::move(other.m_allocator); } } @@ -209,7 +209,7 @@ private: // NOLINTNEXTLINE(*-pointer-arithmetic) for (T* it = data_ptr + old_size; it < end; ++it) { - construct_at(it, ASL_FWD(args)...); + construct_at(it, std::forward(args)...); } } @@ -224,11 +224,11 @@ public: } explicit constexpr buffer(Allocator allocator) - : m_allocator{ASL_MOVE(allocator)} + : m_allocator{std::move(allocator)} {} explicit constexpr buffer(span s, Allocator allocator) - : m_allocator{ASL_MOVE(allocator)} + : m_allocator{std::move(allocator)} { copy_range(s); } @@ -242,9 +242,9 @@ public: constexpr buffer(buffer&& other) requires moveable - : buffer(ASL_MOVE(other.m_allocator)) + : buffer(std::move(other.m_allocator)) { - move_from_other(ASL_MOVE(other), false); + move_from_other(std::move(other), false); } constexpr buffer& operator=(const buffer& other) @@ -259,7 +259,7 @@ public: requires moveable { if (&other == this) { return *this; } - move_from_other(ASL_MOVE(other), true); + move_from_other(std::move(other), true); return *this; } @@ -381,7 +381,7 @@ public: requires constructible_from { T* uninit = push_uninit(); - T* init = construct_at(uninit, ASL_FWD(args)...); + T* init = construct_at(uninit, std::forward(args)...); return *init; } @@ -410,12 +410,12 @@ public: return contiguous_iterator{self.data() + self.size()}; } - constexpr operator span() const // NOLINT(*-explicit-conversions) + constexpr operator span() const // NOLINT(*explicit*) { return as_span(); } - constexpr operator span() // NOLINT(*-explicit-conversions) + constexpr operator span() // NOLINT(*explicit*) { return as_span(); } @@ -429,14 +429,14 @@ public: constexpr auto&& operator[](this auto&& self, isize_t i) { ASL_ASSERT(i >= 0 && i <= self.size()); - return ASL_FWD_LIKE(decltype(self), ASL_FWD(self).data()[i]); + return std::forward_like(std::forward(self).data()[i]); } template requires hashable friend H AslHashValue(H h, const buffer& b) { - return H::combine_contiguous(ASL_MOVE(h), b.as_span()); + return H::combine_contiguous(std::move(h), b.as_span()); } }; -- cgit