std::ignore usage instead of (void) for ignoring return values

This commit is contained in:
Chuck Walbourn
2021-10-17 11:57:07 -07:00
parent 144847dfcc
commit 1363046e2b
12 changed files with 60 additions and 50 deletions

View File

@@ -38,6 +38,7 @@
#include <iterator>
#include <memory>
#include <new>
#include <tuple>
#ifdef __clang__
#pragma clang diagnostic ignored "-Wcovered-switch-default"
@@ -557,7 +558,7 @@ namespace
sRGB = (loadFlags & WIC_LOADER_SRGB_DEFAULT) != 0;
}
(void)PropVariantClear(&value);
std::ignore = PropVariantClear(&value);
if (sRGB)
format = MakeSRGB(format);

View File

@@ -28,6 +28,7 @@
#include <cstring>
#include <iterator>
#include <new>
#include <tuple>
#include <wincodec.h>
@@ -469,7 +470,7 @@ namespace
sRGB = (loadFlags & WIC_LOADER_SRGB_DEFAULT) != 0;
}
(void)PropVariantClear(&value);
std::ignore = PropVariantClear(&value);
if (sRGB)
format = MakeSRGB(format);