Add comments to suppress warning from clang-tidy (#3088)

Suppress style warnings for macro definition, name of these macros is
inconsistent with others (upper case).
This commit is contained in:
Huang Qi
2024-01-26 17:02:24 +08:00
committed by GitHub
parent ad46290770
commit 9fb5fcc709
4 changed files with 11 additions and 3 deletions

View File

@ -46,7 +46,7 @@ static union {
char b;
} __ue = { .a = 1 };
#define is_little_endian() (__ue.b == 1)
#define is_little_endian() (__ue.b == 1) /* NOLINT */
/**
* Implementation of wasm_application_execute_main()

View File

@ -785,6 +785,7 @@ align_ptr(const uint8 *p, uint32 b)
return false; \
} while (0)
/* NOLINTNEXTLINE */
#define read_uint16(p, p_end, res) \
do { \
p = (uint8 *)align_ptr(p, sizeof(uint16)); \
@ -793,6 +794,7 @@ align_ptr(const uint8 *p, uint32 b)
p += sizeof(uint16); \
} while (0)
/* NOLINTNEXTLINE */
#define read_uint32(p, p_end, res) \
do { \
p = (uint8 *)align_ptr(p, sizeof(uint32)); \
@ -3537,7 +3539,7 @@ static union {
char b;
} __ue = { .a = 1 };
#define is_little_endian() (__ue.b == 1)
#define is_little_endian() (__ue.b == 1) /* NOLINT */
bool
wasm_runtime_register_natives(const char *module_name,
@ -4446,6 +4448,7 @@ typedef int64 (*Int64FuncPtr)(GenericFunctionPointer, uint64 *, uint64);
typedef int32 (*Int32FuncPtr)(GenericFunctionPointer, uint64 *, uint64);
typedef void (*VoidFuncPtr)(GenericFunctionPointer, uint64 *, uint64);
/* NOLINTBEGIN */
static volatile Float64FuncPtr invokeNative_Float64 =
(Float64FuncPtr)(uintptr_t)invokeNative;
static volatile Float32FuncPtr invokeNative_Float32 =
@ -4461,6 +4464,7 @@ static volatile VoidFuncPtr invokeNative_Void =
typedef v128 (*V128FuncPtr)(GenericFunctionPointer, uint64 *, uint64);
static V128FuncPtr invokeNative_V128 = (V128FuncPtr)(uintptr_t)invokeNative;
#endif
/* NOLINTEND */
#if defined(_WIN32) || defined(_WIN32_)
#define MAX_REG_FLOATS 4