setjumph.inc 1.2 KB

123456789101112131415161718192021222324252627282930313233343536
  1. {
  2. This file is part of the Free Pascal run time library.
  3. Copyright (c) 2003 by the Free Pascal development team.
  4. SetJmp/Longjmp declarations
  5. See the file COPYING.FPC, included in this distribution,
  6. for details about the copyright.
  7. This program is distributed in the hope that it will be useful,
  8. but WITHOUT ANY WARRANTY; without even the implied warranty of
  9. MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
  10. **********************************************************************}
  11. type
  12. {$ifdef fpc_abi_call0}
  13. jmp_buf = record
  14. a0,a1,a8,a12,a13,a14,a15 : DWord;
  15. end;
  16. {$endif fpc_abi_call0}
  17. {$ifdef fpc_abi_windowed}
  18. jmp_buf = record
  19. data : array[0..16] of DWord;
  20. end;
  21. {$endif fpc_abi_windowed}
  22. pjmp_buf = ^jmp_buf;
  23. {$if defined(freertos) and defined(fpc_abi_windowed)}
  24. function setjmp(var S : jmp_buf) : longint;external;
  25. procedure longjmp(var S : jmp_buf;value : longint);external;
  26. {$else defined(freertos) and defined(fpc_abi_windowed)}
  27. function setjmp(var S : jmp_buf) : longint;[external name 'FPC_SETJMP'];
  28. procedure longjmp(var S : jmp_buf;value : longint);[external name 'FPC_LONGJMP'];
  29. {$endif defined(freertos) and defined(fpc_abi_windowed)}