Subversion Repositories Kolibri OS

Rev

Rev 9810 | Go to most recent revision | Blame | Compare with Previous | Last modification | View Log | Download | RSS feed

  1. #ifndef _STDDEF_H_
  2. #define _STDDEF_H_
  3.  
  4. typedef __SIZE_TYPE__ size_t;
  5. typedef __PTRDIFF_TYPE__ ssize_t;
  6. typedef __WCHAR_TYPE__ wchar_t;
  7. typedef __PTRDIFF_TYPE__ ptrdiff_t;
  8. typedef __PTRDIFF_TYPE__ intptr_t;
  9. typedef __SIZE_TYPE__ uintptr_t;
  10.  
  11. #ifndef NULL
  12. #define NULL ((void*)0)
  13. #endif
  14.  
  15. #ifdef _BUILD_LIBC
  16. #define _FUNC(func) func
  17. #else
  18. #define _FUNC(func) (*func)
  19. #endif
  20.  
  21. #define offsetof(type, field) ((size_t) & ((type*)0)->field)
  22.  
  23. #ifndef __stdcall
  24. #define __stdcall __attribute__((stdcall))
  25. #endif
  26.  
  27. #ifndef __cdecl
  28. #define __cdecl __attribute__((cdecl))
  29. #endif
  30.  
  31. #endif /* _STDDEF_H_ */