dat_isw-funcs.h 1.0 KB

12345678910111213141516171819202122232425262728293031323334353637
  1. /*
  2. * TEST SUITE FOR MB/WC FUNCTIONS IN C LIBRARY
  3. *
  4. * FILE: dat_isw-funcs.h
  5. *
  6. * ISW*: int isw* (wint_t wc);
  7. */
  8. #include <errno.h>
  9. #include <stdlib.h>
  10. #include <wctype.h>
  11. #include "tst_types.h"
  12. #include "tgn_locdef.h"
  13. #define TST_ISW_LOC(FUNC, func) \
  14. TST_ISW## FUNC tst_isw## func ##_loc []
  15. #define TST_ISW_REC(locale, func) \
  16. { Tisw## func, TST_LOC_## locale },
  17. /*
  18. * NOTE:
  19. * Set ret_flg = 1, when a return value is expected to be 0 (FALSE).
  20. * Set ret_flg = 0, when a return value is expected to be non-zero (TRUE).
  21. *
  22. * Since the functions return *non*-zero value for TRUE, can't
  23. * compare an actual return value with an expected return value.
  24. * Set the ret_flg=0 for TRUE cases and the tst_isw*() will check
  25. * the non-zero value.
  26. *
  27. * { { WEOF }, { 0,1,0 } },
  28. * | |
  29. * | ret_val: an expected return value
  30. * ret_flg: if 1, compare an actual return value with the
  31. * ret_val; if 0, the test program
  32. * checks the actual return value.
  33. */