MCPcopy Create free account
hub / github.com/antirez/ds4 / accelerator_tensor_span_cmp

Function accelerator_tensor_span_cmp

ds4.c:2101–2109  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

2099
2100bool ds4_log_is_tty(FILE *fp) {
2101 int fd = fileno(fp);
2102 return fd >= 0 && isatty(fd) != 0;
2103}
2104
2105static void ds4_vlog(FILE *fp, ds4_log_type type, const char *fmt, va_list ap) {
2106 const bool colorize = type != DS4_LOG_DEFAULT && ds4_log_is_tty(fp);
2107 if (colorize) fputs(ds4_log_color_code(type), fp);
2108 vfprintf(fp, fmt, ap);
2109 if (colorize) fputs("\x1b[0m", fp);
2110}
2111
2112void ds4_log(FILE *fp, ds4_log_type type, const char *fmt, ...) {

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected