summaryrefslogtreecommitdiffstats
path: root/Python/strtod.c
blob: 106ec6e136328ca7c45bf140eb489dc0b34a2171 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
/* This is not a proper strtod() implementation, but sufficient for Python.
   Python won't detect floating point constant overflow, though. */

#include <string.h>

extern double atof();

/*ARGSUSED*/
double
strtod(p, pp)
	char *p;
	char **pp;
{
	if (pp)
		*pp = strchr(p, '\0');
	return atof(p);
}