home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
OS/2 Shareware BBS: 10 Tools
/
10-Tools.zip
/
tvos200.zip
/
TVISION
/
_DEFS.H
next >
Wrap
C/C++ Source or Header
|
1995-04-25
|
4KB
|
165 lines
#if !defined(___DEFS_H)
#define ___DEFS_H
/* _defs.h
Common definitions for pointer size and calling conventions.
Calling conventions:
_RTLENTRY Specifies the calling convention used by the RTL
_USERENTRY Specifies the calling convention the RTL expects user
compiled functions to use (for callbacks)
Export (and size for DOS) information:
_EXPCLASS Exports class if building DLL version of library
For DOS16 also provides size information
_EXPDATA Exports data if building DLL version of library
_EXPFUNC Exports function if building DLL version of library
For DOS16 also provides size information
_FAR Promotes data pointers to far in DLLs (DOS16 only)
Obsolete versions:
_Cdecl Use _RTLENTRY
_CLASSTYPE Use _EXPCLASS
_FARFUNC Use _EXPFUNC
_FARCALL Use _EXPFUNC and declare function explicity __far
*/
/*
* C/C++ Run Time Library - Version 1.5
*
* Copyright (c) 1991, 1994 by Borland International
* All Rights Reserved.
*
*/
#if 0 // ifdef __BORLANDC__
# if defined(__MT__)
# define _MT
# endif
# define _RTLENTRY __stdcall
# define _USERENTRY __stdcall
# if defined(__PAS__)
# define _RTLENTRYF __pascal
# else
# define _RTLENTRYF _RTLENTRY
# endif
# define _FAR
# if defined(_BUILDRTLDLL)
# define _EXPCLASS __export
# define _EXPDATA __export
# define _EXPFUNC __export
# else
# define _EXPCLASS
# define _EXPDATA
# define _EXPFUNC
# endif
# define _EXPFUNC32 _EXPFUNC
# define _EXPFUNC16
# define _Cdecl _RTLENTRY
# define _CType _RTLENTRYF
# define _CLASSTYPE _EXPCLASS
# define _FARFUNC _EXPFUNC
# define _FARCALL _EXPFUNC __far
# define _M_IX86 300
# if defined(__cplusplus)
# define _PTRDEF(name) typedef name _FAR * P##name;
# define _REFDEF(name) typedef name _FAR & R##name;
# define _REFPTRDEF(name) typedef name _FAR * _FAR & RP##name;
# define _PTRCONSTDEF(name) typedef const name _FAR * PC##name;
# define _REFCONSTDEF(name) typedef const name _FAR & RC##name;
/*********** Obsolete definitions for OWL 1.0 *************/
# define _CLASSDEF(name) class _EXPCLASS name; \
_PTRDEF(name) \
_REFDEF(name) \
_REFPTRDEF(name) \
_PTRCONSTDEF(name) \
_REFCONSTDEF(name)
# endif
#else
//** Defines for non-borland compilers,
# if defined(__MT__)
# define _MT
# endif
# define BI_NO_NEW_CASTS
# define _RTLENTRY
# define _USERENTRY
# if defined(__PAS__)
# define _RTLENTRYF
# else
# define _RTLENTRYF
# endif
# define _FAR
# if defined(_BUILDRTLDLL)
# define _EXPCLASS // __export
# define _EXPDATA // __export
# define _EXPFUNC // __export
# else
# define _EXPCLASS
# define _EXPDATA
# define _EXPFUNC
# endif
# define _EXPFUNC32 _EXPFUNC
# define _EXPFUNC16
# define _RTL_CDECL _RTLENTRY
# define _RTL_CTYPE _RTLENTRYF
// # define _Cdecl _RTLENTRY replaced by _RTL_CDECL
// # define _CType _RTLENTRYF replaced by _RTL_CTYPE
# define _CLASSTYPE _EXPCLASS
# define _FARFUNC _EXPFUNC
# define _FARCALL _EXPFUNC
# ifndef _M_IX86
# define _M_IX86 300
# endif
# if defined(__cplusplus)
# define _PTRDEF(name) typedef name * P##name;
# define _REFDEF(name) typedef name & R##name;
# define _REFPTRDEF(name) typedef name * & RP##name;
# define _PTRCONSTDEF(name) typedef const name * PC##name;
# define _REFCONSTDEF(name) typedef const name & RC##name;
/*********** Obsolete definitions for OWL 1.0 *************/
# define _CLASSDEF(name) class _EXPCLASS name; \
_PTRDEF(name) \
_REFDEF(name) \
_REFPTRDEF(name) \
_PTRCONSTDEF(name) \
_REFCONSTDEF(name)
# endif
#endif // BORLANDC
#endif /* ___DEFS_H */