Clang-tidy performance error fixes (#411)

Fixes perf errors + ambiguity issues raised by clang-tidy

[ROCm/rocprofiler-sdk commit: 75264b5587]
This commit is contained in:
Benjamin Welton
2024-01-26 10:19:18 -08:00
committed by GitHub
parent 07d551b5cb
commit 24c8d296ba
6 changed files with 21 additions and 21 deletions
@@ -100,9 +100,9 @@ struct static_vector
auto* data() { return m_data.data(); }
const auto* data() const { return m_data.data(); }
void swap(this_type& _v);
void swap(this_type& _v) noexcept;
friend void swap(this_type& _lhs, this_type& _rhs) { _lhs.swap(_rhs); }
friend void swap(this_type& _lhs, this_type& _rhs) noexcept { _lhs.swap(_rhs); }
private:
void update_size(size_t);
@@ -172,7 +172,7 @@ static_vector<Tp, N, AtomicSizeV>::clear()
template <typename Tp, size_t N, bool AtomicSizeV>
void
static_vector<Tp, N, AtomicSizeV>::swap(this_type& _v)
static_vector<Tp, N, AtomicSizeV>::swap(this_type& _v) noexcept
{
if constexpr(AtomicSizeV)
{