• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1 #include <wctype.h>
2 #ifndef __LITEOS__
3 #ifdef FEATURE_ICU_LOCALE
4 #include <string.h>
5 #include "locale_impl.h"
6 #endif
7 #endif
8 
iswlower(wint_t wc)9 int iswlower(wint_t wc)
10 {
11 	return towupper(wc) != wc;
12 }
13 
__iswlower_l(wint_t c,locale_t l)14 int __iswlower_l(wint_t c, locale_t l)
15 {
16 #ifndef __LITEOS__
17 #ifdef FEATURE_ICU_LOCALE
18 	if (icu_locale_wctype_enable && l && l->cat[LC_CTYPE]
19 		&& l->cat[LC_CTYPE]->flag == ICU_VALID) {
20 		char* type_name = (char*)(l->cat[LC_CTYPE]->name);
21 		if (!strcmp(type_name, "zh_CN") || !strcmp(type_name, "en_US.UTF-8")) {
22 			return g_icu_opt_func.u_islower(c);
23 		}
24 	}
25 #endif
26 #endif
27 	return iswlower(c);
28 }
29 
30 weak_alias(__iswlower_l, iswlower_l);
31