Hash :
6fd67ba7
Author :
Date :
2024-03-05T17:10:38
c-strtof, c-strtod, c-strtold: Make multithread-safe. * lib/c-strtod.c: Include <langinfo.h>, c-ctype.h. (decimal_point_char): New function, copied from lib/vasnprintf.c. (C_STRTOD): On platforms that don't have STRTOD_L nor a working uselocale(), pre-parse the number and call STRTOD after having replaced the '.' with the locale-dependent decimal point character. * m4/c-strtod.m4 (gl_C_STRTOD, gl_C_STRTOF, gl_C_STRTOLD): Test for nl_langinfo(). * modules/c-strtof (Depends-on): Add c-ctype. Remove strdup-posix. * modules/c-strtod (Depends-on): Likewise. * modules/c-strtold (Depends-on): Likewise.
Description:
Convert string to float in C locale.
Files:
lib/c-strtod.h
lib/c-strtof.c
lib/c-strtod.c
m4/c-strtod.m4
m4/intl-thread-locale.m4
Depends-on:
c99
extensions
locale
c-ctype
strtof
configure.ac:
gl_C_STRTOF
Makefile.am:
lib_SOURCES += c-strtof.c
Include:
"c-strtod.h"
License:
GPL
Maintainer:
Paul Eggert, Jim Meyering