home *** CD-ROM | disk | FTP | other *** search
/ OS/2 Shareware BBS: 10 Tools / 10-Tools.zip / cset21v1.zip / IBMCPP / INCLUDE / STDDEF.H < prev    next >
Text File  |  1993-09-17  |  3KB  |  89 lines

  1. #pragma info( none )
  2. #ifndef __CHKHDR__
  3.    #pragma info( none )
  4. #endif
  5. #pragma info( restore )
  6.  
  7. #ifndef __stddef_h
  8.    #define __stddef_h
  9.  
  10.    #ifdef __cplusplus
  11.       extern "C" {
  12.    #endif
  13.  
  14.    /********************************************************************/
  15.    /*  <stddef.h> header file                                          */
  16.    /*                                                                  */
  17.    /*  Licensed Materials - Property of IBM                            */
  18.    /*                                                                  */
  19.    /*  IBM C/C++ Tools Version 2.01                                    */
  20.    /*  Copyright (C) International Business Machines Corp., 1991,1993  */
  21.    /*  All rights reserved                                             */
  22.    /*                                                                  */
  23.    /*  US Government Users Restricted Rights -                         */
  24.    /*  Use, duplication, or disclosure restricted                      */
  25.    /*  by GSA ADP Schedule Contract with IBM Corp.                     */
  26.    /*                                                                  */
  27.    /********************************************************************/
  28.  
  29.    typedef int ptrdiff_t;
  30.  
  31.    #ifndef __size_t
  32.       #define __size_t
  33.       typedef unsigned int size_t;
  34.    #endif
  35.  
  36.    #ifndef __wchar_t
  37.       #define __wchar_t
  38.       typedef unsigned short wchar_t;
  39.    #endif
  40.  
  41.    #ifndef NULL
  42.       #if (defined(__EXTENDED__)  || defined( __cplusplus ))
  43.          #define NULL 0
  44.       #else
  45.          #define NULL ((void *)0)
  46.       #endif
  47.    #endif
  48.  
  49.    #ifdef __cplusplus
  50.       #define offsetof(s_name, s_member) (size_t)&(((s_name *)0)->s_member)
  51.    #else
  52.       #define offsetof( x, y ) __offsetof( x, y )
  53.    #endif
  54.  
  55.    #if defined(__EXTENDED__)
  56.  
  57.       #ifndef errno
  58.          #ifdef __MULTI__
  59.             int * _Optlink _errno( void );
  60.             #pragma info( none )
  61.             #define errno (*_errno( ))
  62.             #pragma info( restore )
  63.          #else
  64.             extern int errno;
  65.             #pragma info( none )
  66.             #define errno errno
  67.             #pragma info( restore )
  68.          #endif
  69.       #endif
  70.  
  71.       #ifdef __MULTI__
  72.          unsigned * _Optlink __threadid( void );
  73.          #define _threadid (__threadid( ))
  74.       #endif
  75.  
  76.    #endif
  77.  
  78.    #ifdef __cplusplus
  79.       }
  80.    #endif
  81.  
  82. #endif
  83.  
  84. #pragma info( none )
  85. #ifndef __CHKHDR__
  86.    #pragma info( restore )
  87. #endif
  88. #pragma info( restore )
  89.