source: trunk/include/misc.h@ 1616

Last change on this file since 1616 was 1616, checked in by achimha, 26 years ago

adjust for inclusion in comctl32

File size: 1.4 KB
RevLine 
[1616]1/* $Id: misc.h,v 1.9 1999-11-05 13:03:41 achimha Exp $ */
[4]2
[17]3/*
4 * Miscellaneous definitions
5 * Debug prototypes and macros
6 */
7
8
[4]9#ifndef __MISC_H__
10#define __MISC_H__
11
[780]12#ifndef _OS2WIN_H
13 #include <win32type.h>
14#endif
15
[4]16#ifdef __cplusplus
17 extern "C" {
18#endif
19
[25]20/* enable support for the _interrupt() statement */
21#if (defined(__IBMCPP__) || defined(__IBMC__))
22# include <builtin.h>
23#endif
24
[4]25#ifdef DEBUG
[13]26 #define DebugInt3() _interrupt(3)
[4]27#else
[13]28 #define DebugInt3()
[4]29#endif
30
31
32#ifdef DEBUG
[13]33 #define dprintf(a) WriteLog a
34 #define eprintf(a) WriteLog a ; WriteLogError a
35 #define dassert(a, b) if(!(a)) WriteLogError b
36 #define dbgCheckObj(a) a->checkObject()
[4]37#else
[13]38 #define dprintf(a)
39 #define eprintf(a)
40 #define dassert(a, b)
41 #define dbgCheckObj(a)
[4]42#endif
43
[17]44
[780]45// necessary types
46#ifdef ULONG
47 #error ULONG definition is bad.
48 #define ULONG nope.
[17]49#endif
[1616]50#ifndef NO_ULONG
51 typedef unsigned long ULONG;
52 typedef unsigned long HMODULE;
53#endif
[17]54
55#ifndef SYSTEM
56# define SYSTEM _System
57#endif
58
59
[13]60int SYSTEM WriteLog(char *tekst, ...);
[924]61
[13]62int SYSTEM WriteLogError(char *tekst, ...);
[924]63
[4]64void SYSTEM CheckVersion(ULONG version, char *modname);
[924]65
[4]66void SYSTEM CheckVersionFromHMOD(ULONG version, HMODULE hModule);
67
[924]68int SYSTEM DebugErrorBox(ULONG iErrorCode,
69 char* pszFormat,
70 ...);
71
72
[4]73#ifdef __cplusplus
74 }
75#endif
76
[13]77
[4]78#include "versionos2.h"
79#include "unicode.h"
80
81#endif
Note: See TracBrowser for help on using the repository browser.