stl_wince.h

00001 /*
00002  * File to have Windows CE Toolkit for VC++ 5.0 working with STLport
00003  * 09 - 03 - 1999
00004  * Origin : Giuseppe Govi - g.govi@iol.it
00005  */
00006 
00007 #ifndef _STLP_WINCE_H
00008 #define _STLP_WINCE_H
00009 
00010 // this flag is being used by STLport
00011 #   define _STLP_WINCE
00012 
00013 // tell other parts no iostreams are desired
00014 #   define _STLP_NO_IOSTREAMS 1
00015 
00016 // tell other parts no threads are there
00017 #   define _STLP_NO_THREADS 1
00018 
00019 // not all new-style headers are available...
00020 # define _STLP_HAS_NO_NEW_C_HEADERS
00021 
00022 #     undef _STLP_HAS_NO_EXCEPTIONS
00023 #     define _STLP_HAS_NO_EXCEPTIONS
00024 #     undef _STLP_NO_EXCEPTION_HEADER
00025 #     define _STLP_NO_EXCEPTION_HEADER
00026 
00027 // we have to use malloc instead of new
00028 # undef  _STLP_USE_NEWALLOC
00029 # define _STLP_USE_MALLOC
00030 
00031 //# ifdef _STLP_MSVC
00032 //#     pragma warning (disable: 4786)
00033 //# endif
00034 
00035 #ifdef _STLP_WINCE_USE_OUTPUTDEBUGSTRING
00036 #define _STLP_WINCE_TRACE(msg)   OutputDebugString(msg)
00037 #else
00038 #define _STLP_WINCE_TRACE(msg)   MessageBox(NULL,(msg),NULL,MB_OK)
00039 #endif
00040 
00041 #ifndef __THROW_BAD_ALLOC
00042 #define __THROW_BAD_ALLOC _STLP_WINCE_TRACE(L"out of memory"); ExitThread(1)
00043 #endif
00044 
00045 #ifndef _SIZE_T_DEFINED
00046 typedef unsigned int size_t;
00047 #define _SIZE_T_DEFINED
00048 #endif
00049 
00050 #ifndef __PLACEMENT_NEW_INLINE
00051 inline void *__cdecl operator new(size_t, void *_P) { return (_P); }
00052 #define __PLACEMENT_NEW_INLINE
00053 #endif
00054 
00055 #ifndef _WCHAR_T_DEFINED
00056 typedef unsigned short wchar_t;
00057 #define _WCHAR_T_DEFINED
00058 #endif
00059 
00060 //ptrdiff_t is not defined in Windows CE SDK
00061 #ifndef _PTRDIFF_T_DEFINED
00062 typedef int ptrdiff_t;
00063 #define _PTRDIFF_T_DEFINED
00064 #endif
00065 
00066 #ifndef _ABORT_DEFINED
00067 # define _STLP_ABORT() TerminateProcess(GetCurrentProcess(), 0)
00068 # define _ABORT_DEFINED
00069 #endif
00070 
00071 
00072 #ifndef _ASSERT_DEFINED
00073 # define assert(expr) _STLP_ASSERT(expr)
00074 # define _ASSERT_DEFINED
00075 #endif
00076 
00077 // they say it's needed 
00078 # include <windows.h>
00079 
00080 #endif /* _STLP_WCE_H */
00081 
00082 

Generated on Mon Jun 5 10:20:45 2006 for Intelligence.kdevelop by  doxygen 1.4.6