aboutsummaryrefslogtreecommitdiff
path: root/util.h
diff options
context:
space:
mode:
authorThomas Schmucker <ts@its1.de>2021-07-09 16:21:27 +0200
committerThomas Schmucker <ts@its1.de>2021-07-09 16:21:27 +0200
commit4a3b2cbfbc070da4bc8b13456d6a0bfd81002dee (patch)
treee61b337c567154ad981909b55fda6ad5ab053bdd /util.h
parent9b49671d6f4e72d2c68127bf0106dc75e33dd994 (diff)
downloaddata-structures-4a3b2cbfbc070da4bc8b13456d6a0bfd81002dee.tar.gz
data-structures-4a3b2cbfbc070da4bc8b13456d6a0bfd81002dee.tar.bz2
data-structures-4a3b2cbfbc070da4bc8b13456d6a0bfd81002dee.zip
fix: warning from clang-tidy
Diffstat (limited to 'util.h')
-rw-r--r--util.h9
1 files changed, 4 insertions, 5 deletions
diff --git a/util.h b/util.h
index eb250ae..614c4b0 100644
--- a/util.h
+++ b/util.h
@@ -1,9 +1,9 @@
1#ifndef ITS1_UTIL_H_INCLUDED 1#ifndef ITS1_UTIL_H_INCLUDED
2#define ITS1_UTIL_H_INCLUDED 2#define ITS1_UTIL_H_INCLUDED
3 3
4#include <stdarg.h>
4#include <stdio.h> 5#include <stdio.h>
5#include <stdlib.h> 6#include <stdlib.h>
6#include <stdarg.h>
7 7
8#ifndef NDEBUG 8#ifndef NDEBUG
9static void 9static void
@@ -19,14 +19,13 @@ error(const char *msg, ...)
19 exit(EXIT_FAILURE); 19 exit(EXIT_FAILURE);
20} 20}
21 21
22#define ERROR(msg) error(msg " in \"%s()\" (%s:%d)", __func__, __FILE__, __LINE__) 22# define ERROR(msg) error(msg " in \"%s()\" (%s:%d)", __func__, __FILE__, __LINE__)
23#else 23#else
24#define ERROR(msg) /**/ 24# define ERROR(msg) /**/
25#endif 25#endif
26 26
27#ifndef NELEM 27#ifndef NELEM
28#define NELEM(x) (sizeof(x) / sizeof(x[0])) 28# define NELEM(x) (sizeof(x) / sizeof(x[0])) /* NOLINT */
29#endif 29#endif
30 30
31#endif 31#endif
32