home *** CD-ROM | disk | FTP | other *** search
/ Tricks of the Windows Gam…ming Gurus (2nd Edition) / Disc2.iso / vc98 / include / yvals.h < prev    next >
C/C++ Source or Header  |  1998-06-16  |  2KB  |  92 lines

  1. /* yvals.h values header for Microsoft C/C++ */
  2. #ifndef _YVALS
  3. #define _YVALS
  4. #include <use_ansi.h>
  5.  
  6. /* Define _CRTIMP */
  7. #ifndef _CRTIMP
  8. #ifdef    _DLL
  9. #define _CRTIMP __declspec(dllimport)
  10. #else    /* ndef _DLL */
  11. #define _CRTIMP
  12. #endif    /* _DLL */
  13. #endif    /* _CRTIMP */
  14.  
  15. #ifdef  _MSC_VER
  16. #pragma pack(push,8)
  17. #endif  /* _MSC_VER */
  18.  
  19.  #pragma warning(4: 4018 4114 4146 4244 4245)
  20.  #pragma warning(4: 4663 4664 4665)
  21.  #pragma warning(disable: 4237 4284 4290 4514)
  22.         /* NAMESPACE */
  23.  #if defined(__cplusplus)
  24.   #define _STD            std::
  25.   #define _STD_BEGIN    namespace std {
  26.   #define _STD_END        };
  27.   #define _STD_USING
  28.  #else
  29.   #define _STD            ::
  30.   #define _STD_BEGIN
  31.   #define _STD_END
  32.  #endif /* __cplusplus */
  33. _STD_BEGIN
  34.         /* TYPE bool */
  35.  #if defined(__cplusplus)
  36. typedef bool _Bool;
  37.  #endif /* __cplusplus */
  38.         /* INTEGER PROPERTIES */
  39. #define _MAX_EXP_DIG    8    /* for parsing numerics */
  40. #define _MAX_INT_DIG    32
  41. #define _MAX_SIG_DIG    36
  42.         /* STDIO PROPERTIES */
  43. #define _Filet _iobuf
  44.  
  45. #ifndef _FPOS_T_DEFINED
  46. #define _FPOSOFF(fp)    ((long)(fp))
  47. #endif /* _FPOS_T_DEFINED */
  48.  
  49.         /* NAMING PROPERTIES */
  50.  #if defined(__cplusplus)
  51.   #define _C_LIB_DECL extern "C" {
  52.   #define _END_C_LIB_DECL }
  53.  #else
  54.   #define _C_LIB_DECL
  55.   #define _END_C_LIB_DECL
  56.  #endif /* __cplusplus */
  57. #define _CDECL
  58.         // CLASS _Lockit
  59.  #if defined(__cplusplus)
  60. class _CRTIMP _Lockit
  61.     {    // lock while object in existence
  62. public:
  63.   #ifdef _MT
  64.    #define _LOCKIT(x)    lockit x
  65.     _Lockit();
  66.     ~_Lockit();
  67.   #else
  68.    #define _LOCKIT(x)
  69.     _Lockit()
  70.         {}
  71.     ~_Lockit()
  72.         {}
  73.   #endif /* _MT */
  74.     };
  75.  #endif /* __cplusplus */
  76.         /* MISCELLANEOUS MACROS */
  77. #define _L(c)    L##c
  78. #define _Mbstinit(x)    mbstate_t x = {0}
  79. #define _MAX    _cpp_max
  80. #define _MIN    _cpp_min
  81. _STD_END
  82. #ifdef  _MSC_VER
  83. #pragma pack(pop)
  84. #endif  /* _MSC_VER */
  85.  
  86. #endif /* _YVALS */
  87.  
  88. /*
  89.  * Copyright (c) 1996 by P.J. Plauger.  ALL RIGHTS RESERVED. 
  90.  * Consult your license regarding permissions and restrictions.
  91.  */
  92.