avr-libc-dev
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [avr-libc-dev] Re: [avr-gcc-list] Poll: Who uses itoa() & co with ba


From: Daniel O'Connor
Subject: Re: [avr-libc-dev] Re: [avr-gcc-list] Poll: Who uses itoa() & co with base != {2, 8, 10, 16}?
Date: Sat, 19 Nov 2005 20:56:09 +1030
User-agent: KMail/1.8.2

On Sat, 19 Nov 2005 19:20, Russell Shaw wrote:
> > I'd rather use something like
> >
> > #define _USE_FULL_ITOA
> > #include <stdlib.h>
> >
> > ... itoa(x, s, 13);
>
> That won't save any library space tho. If the reduced version is faster
> and saves a lot of space, then it could be worthwhile having a compile-time
> option.

It will if it's implemented correctly, eg in stdlib.h

#ifdef _USE_FULL_ITOA
#define itoa _itoa_full
#else
#define itoa _itoa_small
#endif

-- 
Daniel O'Connor software and network engineer
for Genesis Software - http://www.gsoft.com.au
"The nice thing about standards is that there
are so many of them to choose from."
  -- Andrew Tanenbaum
GPG Fingerprint - 5596 B766 97C0 0E94 4347 295E E593 DC20 7B3F CE8C

Attachment: pgpkoojpv7HuR.pgp
Description: PGP signature


reply via email to

[Prev in Thread] Current Thread [Next in Thread]