Annotation of mstools/h/stddef.h, revision 1.1.1.4

1.1       root        1: /***
                      2: *stddef.h - definitions/declarations for common constants, types, variables
                      3: *
1.1.1.4 ! root        4: *      Copyright (c) 1985-1993, Microsoft Corporation. All rights reserved.
1.1       root        5: *
                      6: *Purpose:
                      7: *      This file contains definitions and declarations for some commonly
                      8: *      used constants, types, and variables.
                      9: *      [ANSI]
                     10: *
                     11: ****/
                     12: 
                     13: #ifndef _INC_STDDEF
                     14: 
                     15: #ifdef __cplusplus
                     16: extern "C" {
                     17: #endif
                     18: 
                     19: 
1.1.1.3   root       20: /*
                     21:  * Conditional macro definition for function calling type and variable type
                     22:  * qualifiers.
                     23:  */
                     24: #if   ( (_MSC_VER >= 800) && (_M_IX86 >= 300) )
                     25: 
                     26: /*
                     27:  * Definitions for MS C8-32 (386/486) compiler
                     28:  */
                     29: #define _CRTAPI1 __cdecl
                     30: #define _CRTAPI2 __cdecl
                     31: 
                     32: #else
                     33: 
                     34: /*
                     35:  * Other compilers (e.g., MIPS)
                     36:  */
                     37: #define _CRTAPI1
                     38: #define _CRTAPI2
                     39: 
1.1.1.2   root       40: #endif
1.1       root       41: 
1.1.1.3   root       42: 
1.1       root       43: /* define NULL pointer value and the offset() macro */
                     44: 
                     45: #ifndef NULL
                     46: #ifdef __cplusplus
                     47: #define NULL   0
                     48: #else
                     49: #define NULL   ((void *)0)
                     50: #endif
                     51: #endif
                     52: 
                     53: 
                     54: #define offsetof(s,m)  (size_t)&(((s *)0)->m)
                     55: 
                     56: 
                     57: /* declare reference to errno */
                     58: 
                     59: #ifdef _MT
1.1.1.3   root       60: extern int * _CRTAPI1 _errno(void);
1.1       root       61: #define errno  (*_errno())
                     62: #else
                     63: extern int errno;
                     64: #endif
                     65: 
                     66: 
                     67: /* define the implementation dependent size types */
                     68: 
                     69: #ifndef _PTRDIFF_T_DEFINED
                     70: typedef int ptrdiff_t;
                     71: #define _PTRDIFF_T_DEFINED
                     72: #endif
                     73: 
                     74: #ifndef _SIZE_T_DEFINED
                     75: typedef unsigned int size_t;
                     76: #define _SIZE_T_DEFINED
                     77: #endif
                     78: 
                     79: #ifndef _WCHAR_T_DEFINED
                     80: typedef unsigned short wchar_t;
                     81: #define _WCHAR_T_DEFINED
                     82: #endif
                     83: 
                     84: 
                     85: #ifdef _MT
                     86: 
                     87: 
                     88: 
1.1.1.3   root       89: extern unsigned long  _CRTAPI1 __threadid(void);
1.1       root       90: #define _threadid      (__threadid())
1.1.1.3   root       91: extern unsigned long  _CRTAPI1 __threadhandle(void);
1.1       root       92: 
                     93: 
                     94: 
                     95: #endif
                     96: 
                     97: #ifdef __cplusplus
                     98: }
                     99: #endif
                    100: 
                    101: #define _INC_STDDEF
                    102: #endif /* _INC_STDDEF */

unix.superglobalmegacorp.com

This archive runs on limited infrastructure. Preserving old code on modern bandwidth. Automated agents are requested to crawl responsibly.