bug-gawk
[Top][All Lists]
Advanced

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

Re: [bug-gawk] Potential errors in Manual 4.1


From: Aharon Robbins
Subject: Re: [bug-gawk] Potential errors in Manual 4.1
Date: Fri, 29 Aug 2014 11:45:18 +0300
User-agent: Heirloom mailx 12.5 6/20/10

Hello. Thanks for the mail.

> Date: Wed, 27 Aug 2014 14:11:53 +0100
> From: bamber ward <address@hidden>
> To: address@hidden
> Subject: [bug-gawk] Potential errors in Manual 4.1
>
> gawk manual Edition 4.1 April 2014
>
> Section 4.9.1
>
> The program there seems to give the wrong result.

Yes. I have never been happy with it (I didn't originally write it),
so I just now rewrote it.  The new version will get into the git repo
later today.

> typo 7.4.9
>
> In gawk, execution of nextfile causes additional things to happen: any
> ENDFILE rules
>
> are executed except in the case as mentioned below( 'below' should be
> 'above')

I have rewritten this sentence to clarify it.  Thanks.

> zerofile.awk
>
> I note that the syntax error pertains to zerofilef.awk not zerofile.awk  so
> perhaps my formulation of zerofile() is wrong.

It is.

> cat zerofilef.awk
>
> function zerofile(ARGV[Argind], Argind )
> {
>    print ARGIND,Argind, ARGV[Argind]
> }

The correct formulation is

        function zerofile(filename, index_in_argv)
        {
                # body of function here
        }

> page 307
>
> I am doing this in 4.0.1
>
> the lines:
>
> This tells us that gawk is now ready to execute line 67, which decides
> whether to give

I still need to look into this.

Thanks

Arnold



reply via email to

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