aboutsummaryrefslogtreecommitdiffstats
path: root/tools/xc/lib/xc_io.c
blob: 7d75ea245dfd17da170eaffa56e3a4461f274191 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
#include "xc_io.h"

void xcio_error(XcIOContext *ctxt, const char *msg, ...){
  va_list args;

  va_start(args, msg);
  IOStream_vprint(ctxt->info, msg, args);
  va_end(args);
}

void xcio_info(XcIOContext *ctxt, const char *msg, ...){
  va_list args;

  if(!(ctxt->flags & XCFLAGS_VERBOSE)) return;
  va_start(args, msg);
  IOStream_vprint(ctxt->info, msg, args);
  va_end(args);
}

void xcio_debug(XcIOContext *ctxt, const char *msg, ...){
  va_list args;

  if(!(ctxt->flags & XCFLAGS_DEBUG)) return;
  va_start(args, msg);
  IOStream_vprint(ctxt->info, msg, args);
  va_end(args);
}