[PSDK] Update winerror.h. CORE-15682
[reactos.git] / sdk / include / psdk / basetyps.h
1
2 #ifndef _BASETYPS_H
3 #define _BASETYPS_H
4 #pragma once
5
6 #include <guiddef.h>
7
8 #ifndef __OBJC__
9 # ifdef __cplusplus
10 # define EXTERN_C extern "C"
11 # else
12 # define EXTERN_C extern
13 # endif /* __cplusplus */
14 # ifndef _MSC_VER
15 # ifndef __int64
16 # define __int64 long long
17 # endif
18 # ifndef __int32
19 # define __int32 long
20 # endif
21 # ifndef __int16
22 # define __int16 int
23 # endif
24 # ifndef __int8
25 # define __int8 char
26 # endif
27 # endif
28 # ifndef __small
29 # define __small char
30 # endif
31 # ifndef __hyper
32 # define __hyper __int64
33 # endif
34 #endif
35
36 #ifndef STDMETHODCALLTYPE
37 #define STDMETHODCALLTYPE __stdcall
38 #define STDMETHODVCALLTYPE __cdecl
39 #define STDAPICALLTYPE __stdcall
40 #define STDAPIVCALLTYPE __cdecl
41 #define STDAPI EXTERN_C HRESULT STDAPICALLTYPE
42 #define STDAPI_(t) EXTERN_C t STDAPICALLTYPE
43 #define STDMETHODIMP HRESULT STDMETHODCALLTYPE
44 #define STDMETHODIMP_(t) t STDMETHODCALLTYPE
45 #define STDAPIV EXTERN_C HRESULT STDAPIVCALLTYPE
46 #define STDAPIV_(t) EXTERN_C t STDAPIVCALLTYPE
47 #define STDMETHODIMPV HRESULT STDMETHODVCALLTYPE
48 #define STDMETHODIMPV_(t) t STDMETHODVCALLTYPE
49 #endif /* !STDMETHODCALLTYPE */
50
51 #if defined(__cplusplus) && !defined(CINTERFACE)
52 # define interface struct
53 # define STDMETHOD(m) virtual HRESULT STDMETHODCALLTYPE m
54 # define STDMETHOD_(t,m) virtual t STDMETHODCALLTYPE m
55 # define PURE =0
56 # define THIS_
57 # define THIS void
58 # define DECLARE_INTERFACE(i) interface i
59 # define DECLARE_INTERFACE_(i,b) interface i : public b
60 #else
61 # define interface struct
62 # define STDMETHOD(m) HRESULT (STDMETHODCALLTYPE *m)
63 # define STDMETHOD_(t,m) t (STDMETHODCALLTYPE *m)
64 # define PURE
65 # define THIS_ INTERFACE *,
66 # define THIS INTERFACE *
67 # ifdef CONST_VTABLE
68 # define DECLARE_INTERFACE(i) \
69 typedef interface i { const struct i##Vtbl *lpVtbl; } i; \
70 typedef struct i##Vtbl i##Vtbl; \
71 struct i##Vtbl
72 # else
73 # define DECLARE_INTERFACE(i) \
74 typedef interface i { struct i##Vtbl *lpVtbl; } i; \
75 typedef struct i##Vtbl i##Vtbl; \
76 struct i##Vtbl
77 # endif
78 # define DECLARE_INTERFACE_(i,b) DECLARE_INTERFACE(i)
79 #endif
80
81 #ifndef _ERROR_STATUS_T_DEFINED
82 #define _ERROR_STATUS_T_DEFINED
83 typedef unsigned long error_status_t;
84 #endif
85
86 #ifndef _WCHAR_T_DEFINED
87 typedef unsigned short wchar_t;
88 #define _WCHAR_T_DEFINED
89 #endif
90
91 #endif /* _BASETYPS_H_ */