This module defines rudimentary support for debugging and is intended for use by developers only.
The library internally maintains a "current debug level," defined by a non-negative integer. When the level is set to 0, no debugging messages are displayed, and as the level increases, more frequent (or more detailed) debugging messages are displayed.
Developers can call oski_PrintDebugMessage to display debgging information, specifying the level at which the message should appear to the user.
Revision history:
#include <stdio.h>
Go to the source code of this file.
Defines | |
#define | INC_OSKI_DEBUG_H |
oski/debug.h has been included | |
Functions | |
unsigned | oski_GetDebugLevel (void) |
Return the current debugging level. | |
void | oski_SetDebugLevel (unsigned new_level) |
Change the current debugging level. | |
FILE * | oski_GetDebugOutput (void) |
Return the file to which debugging output is currently redirected. | |
void | oski_SetDebugOutput (FILE *fp) |
Change the file to which debugging output is to be redirected. | |
void | oski_PrintDebugMessage (unsigned level, const char *fmt,...) |
Display a debugging message. | |
void | oski_PrintDebugMessageShort (unsigned level, const char *fmt,...) |
Display a debugging message without a trailing newline. |
|
Return the file to which debugging output is currently redirected.
|
|
Display a debugging message.
|
|
Display a debugging message without a trailing newline.
|
|
Change the current debugging level.
|
|
Change the file to which debugging output is to be redirected.
|