util/check: avoid unused parameter warnings

This commit is contained in:
Anthony Towns 2022-04-01 14:10:46 +10:00
parent 1021e4cc68
commit 0add4dbadb

View file

@ -51,7 +51,7 @@ void assertion_fail(const char* file, int line, const char* func, const char* as
/** Helper for Assert()/Assume() */
template <bool IS_ASSERT, typename T>
T&& inline_assertion_check(T&& val, const char* file, int line, const char* func, const char* assertion)
T&& inline_assertion_check(T&& val, [[maybe_unused]] const char* file, [[maybe_unused]] int line, [[maybe_unused]] const char* func, [[maybe_unused]] const char* assertion)
{
if constexpr (IS_ASSERT
#ifdef ABORT_ON_FAILED_ASSUME