Is there a difference between converting a string of ASCII digits to an integer versus a string of non-ASCII digits to an integer?

Harriet Riddle harjitmoe at
Mon Dec 14 17:03:36 CST 2020

Roger L Costello via Unicode wrote:
> […]
> 2. The C function atoi() converts a string of digits to a number. I have seen the source code for atoi(). The source code that I saw was dated around the year 2000. Can you point me to the modern source code for atoi()?
> /Roger

Here is the implementation from the FreeBSD libc:

(|strtol| and |strtol_l| are defined in that source file.  |atoi| and 
|atoi_l| just wrap them, passing |NULL| for |endptr| and |10| for |base|.)

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <>

More information about the Unicode mailing list