68 #define PATH_SEPARATOR "/"
101 static map<string,Message*> *abbrev2Message;
102 static list<Message*> *messages;
107 const string helpText;
122 const char* format, ... );
133 const char* format, ... );
143 static Message* Find(
const char* abbrev );
148 static list<Message*>& MessageList() {
150 messages =
new list<Message*>();
158 const char* helpText,
159 const char* format );
161 const char* Format() {
return format.c_str(); }
162 const char* Abbreviation() {
return abbrev.c_str(); }
163 const char* HelpText() {
return helpText.c_str(); }
164 Action_t Action() {
return action; }
165 void Action(
Action_t a ) {
if( !locked ) { action = a; } }
167 int Locked() {
return locked; }
187 void vlogprintf(
const char* format, va_list args );
194 void logprintf(
const char* format, ... );
201 void warning(
struct Coord_t* location,
const char* format, ... );
206 void error(
struct Coord_t* location,
const char* format, ... );
211 void info(
struct Coord_t* location,
const char* format, ... );
216 void fatal(
struct Coord_t* location,
const char* format, ... );
221 void trace(
struct Coord_t* location,
const char* format, ... );
229 #define MASSERT(c) if(!(c)) { shell_assert( __FILE__, __LINE__ ); abort(); }
235 #define MTHROW_NIL(p) MASSERT(p!=NULL);
static Message * RegisterWarning(CBackend *tool, Action_t defaultAction, const char *abbrev, const char *format,...)
Register a warning message.
void * shell_xmalloc(int s)
Definition: main.cc:369
unsigned long long UINT64
Short cut for unsigned 64 bit integer.
Definition: glue.h:55
void vlogprintf(const char *format, va_list args)
Print to logfile.
int errorCount
Definition: main.cc:291
Plugin's should need these.
Definition: glue.h:89
void fatal(struct Coord_t *location, const char *format,...)
This routine should not be used by plugins.
void shell_xfree(void *p, int s)
Definition: main.cc:365
long INT32
Short cut for signed 32 bit integer.
Definition: glue.h:38
ignore message, don't print or increment counts.
Definition: glue.h:95
signed long long INT64
Short cut for signed 64 bit integer.
Definition: glue.h:51
void message(struct Coord_t *location, Message *message,...)
Print message.
void warning(struct Coord_t *location, const char *format,...)
This routine should not be used by plugins.
Action_t
Message behaviors.
Definition: glue.h:94
void trace(struct Coord_t *location, const char *format,...)
This routine should not be used by plugins.
Structure to hold file coordinates.
Definition: cdecl.h:47
warning message, print and increment warning count
Definition: glue.h:97
void info(struct Coord_t *location, const char *format,...)
This routine should not be used by plugins.
error message, print and increment error count
Definition: glue.h:96
void error(struct Coord_t *location, const char *format,...)
This routine should not be used by plugins.
This is the abstract class to overload to create new backend tools.
Definition: cbackend.h:249
int warningCount
Definition: main.cc:292
unsigned long UINT32
Short cut for unsigned 32 bit integer.
Definition: glue.h:47
informative message, print only
Definition: glue.h:98
FILE * logfile
Definition: main.cc:232
static Message * RegisterError(CBackend *tool, const char *abbrev, const char *format,...)
Register an error message.
void logprintf(const char *format,...)
Print to logfile.
void shell_assert(const char *filename, int linenumber)
Definition: main.cc:362