mirror of
https://github.com/python/cpython.git
synced 2024-11-25 01:20:47 +01:00
16 lines
285 B
C
16 lines
285 B
C
/* This is not a proper strtod() implementation, but sufficient for Python.
|
|
Python won't detect floating point constant overflow, though. */
|
|
|
|
extern int strlen();
|
|
extern double atof();
|
|
|
|
double
|
|
strtod(p, pp)
|
|
char *p;
|
|
char **pp;
|
|
{
|
|
if (pp)
|
|
*pp = p + strlen(p);
|
|
return atof(p);
|
|
}
|