Source code of Windows XP (NT5)
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

58 lines
928 B

  1. /***
  2. *setjmpex.h - definitions/declarations for extended setjmp/longjmp routines
  3. *
  4. * Copyright (c) 1993-2001, Microsoft Corporation. All rights reserved.
  5. *
  6. *Purpose:
  7. * This file causes _setjmpex to be called which will enable safe
  8. * setjmp/longjmp that work correctly with try/except/finally.
  9. *
  10. * [Public]
  11. *
  12. ****/
  13. #if _MSC_VER > 1000
  14. #pragma once
  15. #endif
  16. #ifndef _INC_SETJMPEX
  17. #define _INC_SETJMPEX
  18. #if !defined(_WIN32)
  19. #error ERROR: Only Win32 target supported!
  20. #endif
  21. /*
  22. * Definitions specific to particular setjmp implementations.
  23. */
  24. #if defined(_M_IX86)
  25. /*
  26. * MS compiler for x86
  27. */
  28. #define setjmp _setjmp
  29. #define longjmp _longjmpex
  30. #elif defined(_M_MRX000)
  31. #if _MSC_VER >= 1100
  32. #define _setjmpex _setjmpexVfp
  33. #endif
  34. #define setjmp _setjmpex
  35. #else
  36. #ifdef setjmp
  37. #undef setjmp
  38. #endif
  39. #define setjmp _setjmpex
  40. #endif
  41. #include <setjmp.h>
  42. #endif /* _INC_SETJMPEX */