Silence an unused-parameter warning

On Windows, when using unity build, compilers insist that these are
not used, even though they are; and consequently the build fails.

Pick-to: 6.5
Task-number: QTBUG-109394
Change-Id: I6441134db563e0553a3c9193afe2569fc2ffce85
Reviewed-by: Joerg Bornemann <joerg.bornemann@qt.io>
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
This commit is contained in:
Amir Masoud Abdol 2023-03-09 15:17:19 +01:00
parent d203f82916
commit 3e9f2a0adb

View File

@ -52,7 +52,8 @@ protected:
qsizetype s; // size
void *ptr; // data
Q_ALWAYS_INLINE constexpr void verify(qsizetype pos = 0, qsizetype n = 1) const
Q_ALWAYS_INLINE constexpr void verify([[maybe_unused]] qsizetype pos = 0,
[[maybe_unused]] qsizetype n = 1) const
{
Q_ASSERT(pos >= 0);
Q_ASSERT(pos <= size());