Talk:Itoa

From Wikipedia, the free encyclopedia

Shouldn't there be a mention that itoa is not defined in ANSI-C, and that using this function may cause portability issues with your code since some compilers don't support it?

BrandonMintern 21:51, 14 May 2006 (UTC) Definitely. ANSI C is from 1989, the time that "the C programming language" didn't refer to one of the C standards (89,90,99)is long gone. At the very least point out that modern compilers name it _itoa (they use a prefix _ to make clear the distinction between standard and non-standard names 195.64.89.205 21:36, 13 June 2006 (UTC)

No. Just no. It is arguable enough whether functions should have their own articles *at all*. To make articles for non-standard functions is absurd. Where do we draw the line? Non-standard functions are not a part of the language, so why stop there? Why not list every single function that has ever been written in C? These articles should be deleted. Denis Kasak 00:19, 17 June 2006 (UTC)
I hardly agree, itoa may not be a standard function, but it is used, often. Often enough in my opinion to have it's own article. crashmatrix 09:23, 30 September 2006 (UTC)
Yes, the standard should have it. I just put down my idea on how it got there. Regarding the popularity of the K&R book, itoa first appeared there. So that may be why many people put it in stdlib.h - pietro gagliardi

The example function at freebookzone.com is very broken and probably shouldn't be referred to as an example --

  • it has parameters that differ from "those typically used" (I won't say "standard")
  • it uses malloc
  • it doesn't free one of the mallocs that is only used internally -- memory leak