Skip to content

Commit 3185dca

Browse files
committed
Silence unused parameter warning with UNUSED macro
1 parent 995d3c0 commit 3185dca

File tree

3 files changed

+12
-0
lines changed

3 files changed

+12
-0
lines changed

external/dfdutils/createdfdtest.c

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -7,9 +7,13 @@
77
#include "dfd.h"
88

99
#define TESTRGB565 1
10+
#define UNUSED(x) (void)(x)
1011

1112
int main(int argc, char** argv)
1213
{
14+
UNUSED(argc);
15+
UNUSED(argv);
16+
1317
#ifdef TESTRGBA8888
1418
uint32_t *DFD = createDFDUnpacked(0, 4, 1, 1, s_UNORM);
1519
#endif

external/dfdutils/interpretdfdtest.c

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,8 @@
77
#include <KHR/khr_df.h>
88
#include "dfd.h"
99

10+
#define UNUSED(x) (void)(x)
11+
1012
uint32_t dfd1[] = {
1113
4U + 4U * (KHR_DF_WORD_SAMPLESTART + (4U * KHR_DF_WORD_SAMPLEWORDS)),
1214
((KHR_DF_VENDORID_KHRONOS << KHR_DF_SHIFT_VENDORID) |
@@ -200,6 +202,8 @@ uint32_t dfd6[] = { /* Little-endian unpacked extended (N.B. could be done in tw
200202

201203
int main(int argc, char** argv)
202204
{
205+
UNUSED(argc);
206+
UNUSED(argv);
203207
const char *errorText[] = {
204208
"UNSUPPORTED_NONTRIVIAL_ENDIANNESS",
205209
"UNSUPPORTED_MULTIPLE_SAMPLE_LOCATIONS",

external/dfdutils/testbidirectionalmapping.c

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,8 @@
88
#include "KHR/khr_df.h"
99
#include "dfd.h"
1010

11+
#define UNUSED(x) (void)(x)
12+
1113
const char*
1214
formatname(VkFormat format)
1315
{
@@ -575,6 +577,8 @@ enum VkFormat unmap(uint32_t *dfd)
575577

576578
int main(int argc, char** argv)
577579
{
580+
UNUSED(argc);
581+
UNUSED(argv);
578582
unsigned int i;
579583
for (i = 1; i <= 184; ++i) {
580584
uint32_t *dfd = getmap((enum VkFormat)i);

0 commit comments

Comments
 (0)