/******************************************************************************
 *
 * 9998sketch/error.h
 *
 * (c) Eugene K. Ressler, Jr. 2004, 2005
 *
 * A program related to the book
 *
 * Fundamentals of Virtual World Simulation
 * by Eugene K. Ressler, Jr.
 *
 * No warranty of correctness or capability of any kind is expressed or implied.
 *
 * The author grants free use of this code for any purpose as long any text,
 * executable program, library file, or source code distributed to others 
 * and employing any portion of this code clearly cites the book named above.
 *
 ******************************************************************************/

#ifndef __ERROR_H
#define __ERROR_H

typedef struct source_line_t {
  char *file_name;
  int number;
} SRC_LINE;

extern SRC_LINE no_line;
#define is_no_line_p(L) ((L).number <= 0)

void remark(SRC_LINE line, char *fmt, ...);
void warn(SRC_LINE line, char *fmt, ...);
void err(SRC_LINE line, char *fmt, ...);
void die(SRC_LINE line, char *fmt, ...);
int trouble_p(void);
void report_errors(void);

#endif
