diff options
Diffstat (limited to 'head')
| -rw-r--r-- | head/atas/trace.h | 24 |
1 files changed, 24 insertions, 0 deletions
diff --git a/head/atas/trace.h b/head/atas/trace.h new file mode 100644 index 0000000..a799aa5 --- /dev/null +++ b/head/atas/trace.h @@ -0,0 +1,24 @@ +/* + * Copyright (c) 2026, Apollo Telephone Laboratories. + * Provided under the BSD-3 clause. + */ + +#ifndef ATAS_TRACE_H +#define ATAS_TRACE_H 1 + +#include <stdio.h> + +#if defined(ATAS_DEBUG) +#define trace_debug(fmt, ...) \ + printf("[debug]: " fmt, ##__VA_ARGS__) +#else +#define trace_debug(...) \ + ((void)0) +#endif + +#define trace_warn(fmt, ...) \ + printf("[warning]: " fmt, ##__VA_ARGS__) +#define trace_fatal(fmt, ...) \ + printf("[fatal]: " fmt, ##__VA_ARGS__) + +#endif /* !ATAS_TRACE_H */ |
