Thread overview | ||||||
---|---|---|---|---|---|---|
|
January 03, 2002 itoa and ftoa | ||||
---|---|---|---|---|
| ||||
I've seen atoi() and atof() implemented in string.d, why not itoa() and ftoa() - they are very useful as well. Yes, sprintf() can be used for this purpose - but why not provide a conveniet wrapper around it? |
January 03, 2002 Re: itoa and ftoa | ||||
---|---|---|---|---|
| ||||
Posted in reply to Pavel Minayev | "Pavel Minayev" <evilone@omen.ru> wrote in message news:a108ib$2hga$1@digitaldaemon.com... > I've seen atoi() and atof() implemented in string.d, why > not itoa() and ftoa() - they are very useful as well. > Yes, sprintf() can be used for this purpose - but why > not provide a conveniet wrapper around it? OutBuffer will work as a wrapper around it, though I intend to make a collection of toString(type) functions. |
January 03, 2002 Re: itoa and ftoa | ||||
---|---|---|---|---|
| ||||
Posted in reply to Walter | "Walter" <walter@digitalmars.com> wrote in message news:a109lv$2i67$1@digitaldaemon.com... > OutBuffer will work as a wrapper around it, though I intend to make a collection of toString(type) functions. That'd be great, since creating an OutBuffer each time it's needed to convert number to string is $#%&. BTW do you mind if I borrow the printf() and vprintf() code from OutBuffer to use in Stream? |
January 03, 2002 Re: itoa and ftoa | ||||
---|---|---|---|---|
| ||||
Posted in reply to Pavel Minayev | "Pavel Minayev" <evilone@omen.ru> wrote in message news:a10a02$2ifr$1@digitaldaemon.com... > BTW do you mind if I borrow the printf() and vprintf() code > from OutBuffer to use in Stream? Please, go right ahead! |
Copyright © 1999-2021 by the D Language Foundation