[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [avr-libc-dev] Working octal code (FYI)
From: |
David Brown |
Subject: |
Re: [avr-libc-dev] Working octal code (FYI) |
Date: |
Fri, 16 Dec 2016 14:43:29 +0100 |
User-agent: |
Mozilla/5.0 (X11; Linux x86_64; rv:24.0) Gecko/20100101 Thunderbird/24.2.0 |
On 16/12/16 09:56, Dale Whitfield wrote:
> Hi George,
>
>> (Am I annoying everyone by using this mailing list as my personal
>> coding blog?)
>>
>
> No. But I speak for myself.
>
> Some of us are interested and reading but don't have time to comment or
> to work through the code.
>
> Your efforts are appreciated.
>
My feelings are much the same.
I would not put in too much effort into making this code fast (except
for the fun of it, of course). Printing in octal is necessary to make
printf long long support complete. But it is unlikely to be useful in
practice - people very rarely use octal. I can think of only 4 use-cases:
1. chmod parameters on *nix.
2. 0 is an octal constant in C, and is often quite handy.
3. "uint8_t month = 09;" is a fine way to get accidental compile-time
errors.
4. "uint16_t year_of_nicaea = 0325;" is a fine way to get accidental
run-time errors.
Still, as long as octal is in the C standards, it is great that you are
doing this work to finish the standard support in printf.
- [avr-libc-dev] Printing octal (brain dump), George Spelvin, 2016/12/14
- [avr-libc-dev] Working octal code (FYI), George Spelvin, 2016/12/16
- Re: [avr-libc-dev] Printing octal (brain dump), George Spelvin, 2016/12/19
- Re: [avr-libc-dev] Printing octal (brain dump), Georg-Johann Lay, 2016/12/19
- Re: [avr-libc-dev] Printing octal (brain dump), Georg-Johann Lay, 2016/12/21
- Re: [avr-libc-dev] Printing octal (brain dump), George Spelvin, 2016/12/21
- [avr-libc-dev] Even faster decimal code, George Spelvin, 2016/12/23
- Re: [avr-libc-dev] Even faster decimal code, Georg-Johann Lay, 2016/12/24