#include <assert.h>
#include <stdio.h>
浏览源代码.
|
| #define | MNN_PRINT(format, ...) printf(format, ##__VA_ARGS__) |
| |
| #define | MNN_ERROR(format, ...) printf(format, ##__VA_ARGS__) |
| |
| #define | MNN_ASSERT(x) |
| |
| #define | FUNC_PRINT(x) MNN_PRINT(#x "=%d in %s, %d \n", x, __func__, __LINE__); |
| |
| #define | FUNC_PRINT_ALL(x, type) MNN_PRINT(#x "=" #type " %" #type " in %s, %d \n", x, __func__, __LINE__); |
| |
| #define | MNN_PUBLIC __attribute__((visibility("default"))) |
| |
◆ FUNC_PRINT
| #define FUNC_PRINT |
( |
|
x | ) |
MNN_PRINT(#x "=%d in %s, %d \n", x, __func__, __LINE__); |
◆ FUNC_PRINT_ALL
| #define FUNC_PRINT_ALL |
( |
|
x, |
|
|
|
type |
|
) |
| MNN_PRINT(#x "=" #type " %" #type " in %s, %d \n", x, __func__, __LINE__); |
◆ MNN_ASSERT
值:{ \
int res = (x); \
if (!res) { \
MNN_ERROR("Error for %s, %d\n", __FILE__, __LINE__); \
} \
}
◆ MNN_ERROR
| #define MNN_ERROR |
( |
|
format, |
|
|
|
... |
|
) |
| printf(format, ##__VA_ARGS__) |
◆ MNN_PRINT
| #define MNN_PRINT |
( |
|
format, |
|
|
|
... |
|
) |
| printf(format, ##__VA_ARGS__) |
◆ MNN_PUBLIC
| #define MNN_PUBLIC __attribute__((visibility("default"))) |