forked from Imagelibrary/rtems
* Makefile.am, preinstall.am, libmisc/Makefile.am, wrapup/Makefile.am: Add the stringto family of string to number converters. These are error checking wrappers for the strtoXXX methods and do their best to return false if the conversion failed. The error checking required for this is tedious and error prone. Hence better to have in a family of helper routines. * libmisc/stringto/stringto.h, libmisc/stringto/stringto_template.h, libmisc/stringto/stringtodouble.c, libmisc/stringto/stringtofloat.c, libmisc/stringto/stringtoint.c, libmisc/stringto/stringtolong.c, libmisc/stringto/stringtolonglong.c, libmisc/stringto/stringtounsignedchar.c, libmisc/stringto/stringtounsignedint.c, libmisc/stringto/stringtounsignedlong.c, libmisc/stringto/stringtounsignedlonglong.c: New files.
21 lines
520 B
C
21 lines
520 B
C
/*
|
|
* COPYRIGHT (c) 2009.
|
|
* On-Line Applications Research Corporation (OAR).
|
|
*
|
|
* The license and distribution terms for this file may be
|
|
* found in the file LICENSE in this distribution or at
|
|
* http://www.rtems.com/license/LICENSE.
|
|
*
|
|
* $Id$
|
|
*/
|
|
|
|
/*
|
|
* Instantiate an error checking wrapper for strtof (float)
|
|
*/
|
|
#define STRING_TO_FLOAT
|
|
#define STRING_TO_TYPE float
|
|
#define STRING_TO_NAME rtems_string_to_float
|
|
#define STRING_TO_METHOD strtof
|
|
#define STRING_TO_MAX HUGE_VALF
|
|
#include "stringto_template.h"
|