Panda3D
Functions
pstrtod.h File Reference

PANDA 3D SOFTWARE Copyright (c) Carnegie Mellon University. More...

#include "dtoolbase.h"

Go to the source code of this file.

Functions

double patof (const char *str)
 This function re-implements atof, to avoid the problems that occur when the LC_NUMERIC locale gets set to anything other than "C". More...
 
double pstrtod (const char *nptr, char **endptr)
 This function re-implements strtod, to avoid the problems that occur when the LC_NUMERIC locale gets set to anything other than "C". More...
 

Detailed Description

PANDA 3D SOFTWARE Copyright (c) Carnegie Mellon University.

All rights reserved.

All use of this software is subject to the terms of the revised BSD license. You should have received a copy of this license along with this source code in a file named "LICENSE."

Author
drose
Date
2009-06-13

Definition in file pstrtod.h.

Function Documentation

◆ patof()

double patof ( const char *  str)

This function re-implements atof, to avoid the problems that occur when the LC_NUMERIC locale gets set to anything other than "C".

Regardless of the user's locale, we need to be able to parse floating-point numbers internally understanding a "." as the decimal point.

Definition at line 156 of file pstrtod.cxx.

References pstrtod().

◆ pstrtod()

double pstrtod ( const char *  nptr,
char **  endptr 
)

This function re-implements strtod, to avoid the problems that occur when the LC_NUMERIC locale gets set to anything other than "C".

Regardless of the user's locale, we need to be able to parse floating-point numbers internally understanding a "." as the decimal point.

Definition at line 31 of file pstrtod.cxx.

Referenced by patof(), and string_to_double().