glue.inc 1.4 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253
  1. { ---------------------------------------------------------------------
  2. glue.inc : Glue between libc and Pascal types
  3. ---------------------------------------------------------------------}
  4. Type
  5. __ptr_t = Pointer;
  6. P__ptr_t = ^__ptr_t;
  7. ptrdiff_t = Integer;
  8. __long_double_t = Extended;
  9. P__long_double_t = ^__long_double_t;
  10. size_t = Cardinal;
  11. Psize_t = ^size_t;
  12. UInt64 = 0..High(Int64); // Must be unsigned.
  13. wchar_t = widechar;
  14. Pwchar_t = ^wchar_t;
  15. PPwchar_t = ^Pwchar_t;
  16. PPByte = ^PByte;
  17. PPPChar = ^PPChar;
  18. { ---------------------------------------------------------------------
  19. Declarations moved forward because C headers are a mess.
  20. ---------------------------------------------------------------------}
  21. Type
  22. __sighandler_t = procedure(SigNum: Integer); cdecl;
  23. timespec = record
  24. tv_sec: Longint;
  25. tv_nsec: Longint;
  26. end;
  27. wint_t = Cardinal;
  28. __mbstate_t = record
  29. count: Integer;
  30. case { __value } Integer of
  31. 0: (__wch: wint_t);
  32. 1: (__wchb: packed array[0..4 - 1] of Char);
  33. end;
  34. mbstate_t = __mbstate_t;
  35. P__mbstate_t = ^__mbstate_t;
  36. { ---------------------------------------------------------------------
  37. Borland compatibility types for forward declarations.
  38. ---------------------------------------------------------------------}
  39. TSignalHandler = __sighandler_t;
  40. TTimeSpec = timespec;
  41. PTimeSpec = ^TTimeSpec;
  42. TMultiByteState = __mbstate_t;
  43. PMultiByteState = ^TMultiByteState;