mirror of
https://github.com/tillitis/tillitis-key1.git
synced 2024-12-20 13:24:24 -05:00
c443ef8a3e
Add clang-tidy and splint static analytics check. For now, we use only the cert-* warnings on clang-tidy and run splint with a lot of flags to allow more things. Changes to silence these analytics: - Stop returning stuff from our debug print functions. We don't check them anyway and we don't have any way of detecting transmission failure. - Declare more things static that isn't used outside of a file. - Change types to be more consistent, typically to size_t or something or to uint32_t.
16 lines
392 B
C
16 lines
392 B
C
/*
|
|
* Copyright (C) 2022, 2023 - Tillitis AB
|
|
* SPDX-License-Identifier: GPL-2.0-only
|
|
*/
|
|
|
|
#ifndef ASSERT_H
|
|
#define ASSERT_H
|
|
|
|
#define assert(expr) \
|
|
((expr) ? (void)(0) : assert_fail(#expr, __FILE__, __LINE__, __func__))
|
|
|
|
void assert_fail(const char *assertion, const char *file, unsigned int line,
|
|
const char *function);
|
|
|
|
#endif
|