|
@@ -207,6 +207,11 @@ int abs(int j)
|
|
|
|
|
|
#ifdef L_labs
|
|
|
|
|
|
+long int labs(long int j)
|
|
|
+{
|
|
|
+ return (j >= 0) ? j : -j;
|
|
|
+}
|
|
|
+
|
|
|
#if UINT_MAX == ULONG_MAX
|
|
|
strong_alias(labs,abs)
|
|
|
#endif
|
|
@@ -219,26 +224,21 @@ strong_alias(labs,llabs)
|
|
|
strong_alias(labs,imaxabs)
|
|
|
#endif
|
|
|
|
|
|
-long int labs(long int j)
|
|
|
-{
|
|
|
- return (j >= 0) ? j : -j;
|
|
|
-}
|
|
|
-
|
|
|
#endif
|
|
|
|
|
|
#ifdef L_llabs
|
|
|
|
|
|
#if defined(ULLONG_MAX) && (LLONG_MAX > LONG_MAX)
|
|
|
|
|
|
-#if (ULLONG_MAX == UINTMAX_MAX)
|
|
|
-strong_alias(llabs,imaxabs)
|
|
|
-#endif
|
|
|
-
|
|
|
long long int llabs(long long int j)
|
|
|
{
|
|
|
return (j >= 0) ? j : -j;
|
|
|
}
|
|
|
|
|
|
+#if (ULLONG_MAX == UINTMAX_MAX)
|
|
|
+strong_alias(llabs,imaxabs)
|
|
|
+#endif
|
|
|
+
|
|
|
#endif
|
|
|
|
|
|
#endif
|
|
@@ -258,6 +258,11 @@ int atoi(const char *nptr)
|
|
|
|
|
|
#ifdef L_atol
|
|
|
|
|
|
+long atol(const char *nptr)
|
|
|
+{
|
|
|
+ return strtol(nptr, (char **) NULL, 10);
|
|
|
+}
|
|
|
+
|
|
|
#if UINT_MAX == ULONG_MAX
|
|
|
strong_alias(atol,atoi)
|
|
|
#endif
|
|
@@ -266,11 +271,6 @@ strong_alias(atol,atoi)
|
|
|
strong_alias(atol,atoll)
|
|
|
#endif
|
|
|
|
|
|
-long atol(const char *nptr)
|
|
|
-{
|
|
|
- return strtol(nptr, (char **) NULL, 10);
|
|
|
-}
|
|
|
-
|
|
|
#endif
|
|
|
|
|
|
#ifdef L_atoll
|
|
@@ -288,6 +288,12 @@ long long atoll(const char *nptr)
|
|
|
|
|
|
#if defined(L_strtol) || defined(L_strtol_l)
|
|
|
|
|
|
+long __XL(strtol)(const char * __restrict str, char ** __restrict endptr,
|
|
|
+ int base __LOCALE_PARAM )
|
|
|
+{
|
|
|
+ return __XL_NPP(_stdlib_strto_l)(str, endptr, base, 1 __LOCALE_ARG );
|
|
|
+}
|
|
|
+
|
|
|
#if (ULONG_MAX == UINTMAX_MAX) && !defined(L_strtol_l)
|
|
|
strong_alias(strtol,strtoimax)
|
|
|
#endif
|
|
@@ -296,12 +302,6 @@ strong_alias(strtol,strtoimax)
|
|
|
strong_alias(__XL(strtol),__XL(strtoll))
|
|
|
#endif
|
|
|
|
|
|
-long __XL(strtol)(const char * __restrict str, char ** __restrict endptr,
|
|
|
- int base __LOCALE_PARAM )
|
|
|
-{
|
|
|
- return __XL_NPP(_stdlib_strto_l)(str, endptr, base, 1 __LOCALE_ARG );
|
|
|
-}
|
|
|
-
|
|
|
__XL_ALIAS(strtol)
|
|
|
|
|
|
#endif
|
|
@@ -310,13 +310,6 @@ __XL_ALIAS(strtol)
|
|
|
|
|
|
#if defined(ULLONG_MAX) && (LLONG_MAX > LONG_MAX)
|
|
|
|
|
|
-#if !defined(L_strtoll_l)
|
|
|
-#if (ULLONG_MAX == UINTMAX_MAX)
|
|
|
-strong_alias(strtoll,strtoimax)
|
|
|
-#endif
|
|
|
-strong_alias(strtoll,strtoq)
|
|
|
-#endif
|
|
|
-
|
|
|
long long __XL(strtoll)(const char * __restrict str,
|
|
|
char ** __restrict endptr, int base
|
|
|
__LOCALE_PARAM )
|
|
@@ -325,6 +318,13 @@ long long __XL(strtoll)(const char * __restrict str,
|
|
|
__LOCALE_ARG );
|
|
|
}
|
|
|
|
|
|
+#if !defined(L_strtoll_l)
|
|
|
+#if (ULLONG_MAX == UINTMAX_MAX)
|
|
|
+strong_alias(strtoll,strtoimax)
|
|
|
+#endif
|
|
|
+strong_alias(strtoll,strtoq)
|
|
|
+#endif
|
|
|
+
|
|
|
__XL_ALIAS(strtoll)
|
|
|
|
|
|
#endif
|
|
@@ -333,6 +333,13 @@ __XL_ALIAS(strtoll)
|
|
|
|
|
|
#if defined(L_strtoul) || defined(L_strtoul_l)
|
|
|
|
|
|
+unsigned long __XL(strtoul)(const char * __restrict str,
|
|
|
+ char ** __restrict endptr, int base
|
|
|
+ __LOCALE_PARAM )
|
|
|
+{
|
|
|
+ return __XL_NPP(_stdlib_strto_l)(str, endptr, base, 0 __LOCALE_ARG );
|
|
|
+}
|
|
|
+
|
|
|
#if (ULONG_MAX == UINTMAX_MAX) && !defined(L_strtoul_l)
|
|
|
strong_alias(strtoul,strtoumax)
|
|
|
#endif
|
|
@@ -341,13 +348,6 @@ strong_alias(strtoul,strtoumax)
|
|
|
strong_alias(__XL(strtoul),__XL(strtoull))
|
|
|
#endif
|
|
|
|
|
|
-unsigned long __XL(strtoul)(const char * __restrict str,
|
|
|
- char ** __restrict endptr, int base
|
|
|
- __LOCALE_PARAM )
|
|
|
-{
|
|
|
- return __XL_NPP(_stdlib_strto_l)(str, endptr, base, 0 __LOCALE_ARG );
|
|
|
-}
|
|
|
-
|
|
|
__XL_ALIAS(strtoul)
|
|
|
|
|
|
#endif
|
|
@@ -356,13 +356,6 @@ __XL_ALIAS(strtoul)
|
|
|
|
|
|
#if defined(ULLONG_MAX) && (LLONG_MAX > LONG_MAX)
|
|
|
|
|
|
-#if !defined(L_strtoull_l)
|
|
|
-#if (ULLONG_MAX == UINTMAX_MAX)
|
|
|
-strong_alias(strtoull,strtoumax)
|
|
|
-#endif
|
|
|
-strong_alias(strtoull,strtouq)
|
|
|
-#endif
|
|
|
-
|
|
|
unsigned long long __XL(strtoull)(const char * __restrict str,
|
|
|
char ** __restrict endptr, int base
|
|
|
__LOCALE_PARAM )
|
|
@@ -370,6 +363,13 @@ unsigned long long __XL(strtoull)(const char * __restrict str,
|
|
|
return __XL_NPP(_stdlib_strto_ll)(str, endptr, base, 0 __LOCALE_ARG );
|
|
|
}
|
|
|
|
|
|
+#if !defined(L_strtoull_l)
|
|
|
+#if (ULLONG_MAX == UINTMAX_MAX)
|
|
|
+strong_alias(strtoull,strtoumax)
|
|
|
+#endif
|
|
|
+strong_alias(strtoull,strtouq)
|
|
|
+#endif
|
|
|
+
|
|
|
__XL_ALIAS(strtoull)
|
|
|
|
|
|
#endif
|
|
@@ -953,6 +953,12 @@ size_t wcstombs(char * __restrict s, const wchar_t * __restrict pwcs, size_t n)
|
|
|
|
|
|
#if defined(L_wcstol) || defined(L_wcstol_l)
|
|
|
|
|
|
+long __XL(wcstol)(const wchar_t * __restrict str,
|
|
|
+ wchar_t ** __restrict endptr, int base __LOCALE_PARAM )
|
|
|
+{
|
|
|
+ return __XL_NPP(_stdlib_wcsto_l)(str, endptr, base, 1 __LOCALE_ARG );
|
|
|
+}
|
|
|
+
|
|
|
#if (ULONG_MAX == UINTMAX_MAX) && !defined(L_wcstol_l)
|
|
|
strong_alias(wcstol,wcstoimax)
|
|
|
#endif
|
|
@@ -961,12 +967,6 @@ strong_alias(wcstol,wcstoimax)
|
|
|
strong_alias(__XL(wcstol),__XL(wcstoll))
|
|
|
#endif
|
|
|
|
|
|
-long __XL(wcstol)(const wchar_t * __restrict str,
|
|
|
- wchar_t ** __restrict endptr, int base __LOCALE_PARAM )
|
|
|
-{
|
|
|
- return __XL_NPP(_stdlib_wcsto_l)(str, endptr, base, 1 __LOCALE_ARG );
|
|
|
-}
|
|
|
-
|
|
|
__XL_ALIAS(wcstol)
|
|
|
|
|
|
#endif
|
|
@@ -975,13 +975,6 @@ __XL_ALIAS(wcstol)
|
|
|
|
|
|
#if defined(ULLONG_MAX) && (LLONG_MAX > LONG_MAX)
|
|
|
|
|
|
-#if !defined(L_wcstoll_l)
|
|
|
-#if (ULLONG_MAX == UINTMAX_MAX)
|
|
|
-strong_alias(wcstoll,wcstoimax)
|
|
|
-#endif
|
|
|
-strong_alias(wcstoll,wcstoq)
|
|
|
-#endif
|
|
|
-
|
|
|
long long __XL(wcstoll)(const wchar_t * __restrict str,
|
|
|
wchar_t ** __restrict endptr, int base
|
|
|
__LOCALE_PARAM )
|
|
@@ -990,6 +983,13 @@ long long __XL(wcstoll)(const wchar_t * __restrict str,
|
|
|
__LOCALE_ARG );
|
|
|
}
|
|
|
|
|
|
+#if !defined(L_wcstoll_l)
|
|
|
+#if (ULLONG_MAX == UINTMAX_MAX)
|
|
|
+strong_alias(wcstoll,wcstoimax)
|
|
|
+#endif
|
|
|
+strong_alias(wcstoll,wcstoq)
|
|
|
+#endif
|
|
|
+
|
|
|
__XL_ALIAS(wcstoll)
|
|
|
|
|
|
#endif
|
|
@@ -998,6 +998,13 @@ __XL_ALIAS(wcstoll)
|
|
|
|
|
|
#if defined(L_wcstoul) || defined(L_wcstoul_l)
|
|
|
|
|
|
+unsigned long __XL(wcstoul)(const wchar_t * __restrict str,
|
|
|
+ wchar_t ** __restrict endptr, int base
|
|
|
+ __LOCALE_PARAM )
|
|
|
+{
|
|
|
+ return __XL_NPP(_stdlib_wcsto_l)(str, endptr, base, 0 __LOCALE_ARG );
|
|
|
+}
|
|
|
+
|
|
|
#if (ULONG_MAX == UINTMAX_MAX) && !defined(L_wcstoul_l)
|
|
|
strong_alias(wcstoul,wcstoumax)
|
|
|
#endif
|
|
@@ -1006,13 +1013,6 @@ strong_alias(wcstoul,wcstoumax)
|
|
|
strong_alias(__XL(wcstoul),__XL(wcstoull))
|
|
|
#endif
|
|
|
|
|
|
-unsigned long __XL(wcstoul)(const wchar_t * __restrict str,
|
|
|
- wchar_t ** __restrict endptr, int base
|
|
|
- __LOCALE_PARAM )
|
|
|
-{
|
|
|
- return __XL_NPP(_stdlib_wcsto_l)(str, endptr, base, 0 __LOCALE_ARG );
|
|
|
-}
|
|
|
-
|
|
|
__XL_ALIAS(wcstoul)
|
|
|
|
|
|
#endif
|
|
@@ -1021,13 +1021,6 @@ __XL_ALIAS(wcstoul)
|
|
|
|
|
|
#if defined(ULLONG_MAX) && (LLONG_MAX > LONG_MAX)
|
|
|
|
|
|
-#if !defined(L_wcstoull_l)
|
|
|
-#if (ULLONG_MAX == UINTMAX_MAX)
|
|
|
-strong_alias(wcstoull,wcstoumax)
|
|
|
-#endif
|
|
|
-strong_alias(wcstoull,wcstouq)
|
|
|
-#endif
|
|
|
-
|
|
|
unsigned long long __XL(wcstoull)(const wchar_t * __restrict str,
|
|
|
wchar_t ** __restrict endptr, int base
|
|
|
__LOCALE_PARAM )
|
|
@@ -1035,6 +1028,13 @@ unsigned long long __XL(wcstoull)(const wchar_t * __restrict str,
|
|
|
return __XL_NPP(_stdlib_wcsto_ll)(str, endptr, base, 0 __LOCALE_ARG );
|
|
|
}
|
|
|
|
|
|
+#if !defined(L_wcstoull_l)
|
|
|
+#if (ULLONG_MAX == UINTMAX_MAX)
|
|
|
+strong_alias(wcstoull,wcstoumax)
|
|
|
+#endif
|
|
|
+strong_alias(wcstoull,wcstouq)
|
|
|
+#endif
|
|
|
+
|
|
|
__XL_ALIAS(wcstoull)
|
|
|
|
|
|
#endif
|