bug-gawk
[Top][All Lists]
Advanced

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

Re: [bug-gawk] pretty-print eats header comments


From: Aharon Robbins
Subject: Re: [bug-gawk] pretty-print eats header comments
Date: Wed, 24 Dec 2014 18:05:26 +0200
User-agent: Heirloom mailx 12.5 6/20/10

Hi.

Sorry for the long delay in replying.

The code in the master branch has been improved and you should
see more reasonable results now when pretty printing.

Thanks,

Arnold

> Date: Sun, 02 Nov 2014 13:52:06 +0100
> From: Hermann Peifer <address@hidden>
> To: "address@hidden" <address@hidden>
> Subject: [bug-gawk] pretty-print eats header comments
>
> Hi again.
>
> Arnold wrote the other day about excising remaining problems of the 
> pretty printer. Here is what I just found: header comments are gone in 
> cases where the BEGIN rule starts with a comment (see test1.awk) whereas 
> they are kept in the test2.awk example.
>
> Hermann
>
> ==> test1.awk <==
>
> $ cat test1.awk
> # Some
> # comments
> # here
> #
> BEGIN { # Field separator
>       FS = "\t"
> }
>
> $ awk -o/dev/stdout -f test1.awk
> # Field separator
> BEGIN {
>       FS = "\t"
> }
>
> ==> test2.awk <==
>
> $ cat test2.awk
> # Some
> # comments
> # here
> #
> BEGIN {
>       FS = "\t" # Field separator
> }
>
> $ awk -o/dev/stdout -f test2.awk
> # Some
> # comments
> # here
> #
> BEGIN {
>       FS = "\t"
>       # Field separator
> }



reply via email to

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