[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: gawk-3.1.8 printf doesn't handle %08s leading zeros anymore
From: |
Aharon Robbins |
Subject: |
Re: gawk-3.1.8 printf doesn't handle %08s leading zeros anymore |
Date: |
Sat, 26 Feb 2011 21:26:25 +0200 |
User-agent: |
Heirloom mailx 12.4 7/29/08 |
Hi. Re this:
> Date: Fri, 25 Feb 2011 15:18:10 +0100
> To: address@hidden
> From: Franz Sirl <address@hidden>
> Subject: gawk-3.1.8 printf doesn't handle %08s leading zeros anymore
>
> Hi,
>
> this simple script doesn't work anymore as documented:
>
> gawk 'BEGIN{printf "%08s", "xx"}'
>
> According to the documentation it should print '000000xx', but it prints
> ' xx' now. This worked until gawk-3.1.7.
>
> Franz
Thanks for the report. However, it's deliberate. If you look at
the NEWS file, you will see:
> Changes from 3.1.7 to 3.1.8
> ---------------------------
> 1. The zero flag no longer applies to %c and %s; apparently the standards
> changed at some point.
I may have missed updating the documentation. I'll double check that it
is fixed in the upcoming development version.
Thanks,
Arnold