Museum

Home

Lab Overview

Retrotechnology Articles

Online Manuals

⇒ atof(3C) — GL2 W2.5r1

Media Vault

Software Library

Restoration Projects

Artifacts Sought

Related Articles

fpsigset(3C)

scanf(3S)

strtol(3C)

ATOF(3C)  —  Silicon Graphics

NAME

atof,_latof − convert ASCII string to floating-point number

SYNOPSIS

float atof (nptr)
char ∗nptr;

long float _latof (nptr)
char ∗nptr;

DESCRIPTION

(_l)atof converts a character string pointed to by nptr to a floating-point number of the indicated precision.  The first unrecognized character ends the conversion.  (_l)atof recognizes an optional string of white-space characters (tabs and spaces), then an optional sign, then a string of digits optionally containing a decimal point, then an optional e or E followed by an optionally signed integer.  If the string begins with an unrecognized character, (_l)atof returns the value zero. 

DIAGNOSTICS

The low-level floating point routines will raise a floating point exception if the conversion done by (_l)atof overflows or underflows. 

SEE ALSO

fpsigset(3C), scanf(3S), strtol(3C). 

Version 2.5r1  —  October 29, 1986

Typewritten Software • bear@typewritten.org • Edmonds, WA 98026