Subject: Re: Replacing in-tree gawk with nawk ?
To: =?iso-8859-1?Q?Jarom=EDr_Dolecek?= <dolecek@ics.muni.cz>
From: Antti Kantee <pooka@iki.fi>
List: tech-userlevel
Date: 01/18/2001 15:43:20
On Thu Jan 18 2001 at 12:35:48 +0100, Jaromír Dolecek wrote:
> Simon Burge wrote:
> > My only concern would be that people might have used GNUisms
> > in existing scripts and that these would break.  Do you have
> > a comparision of language features between the two?
> 
> Well, hopefully not much - awk is defined by POSIX, after all.
> gawk manpage mentions these extensions in description of --posix
> flag:
>               o \x escape sequences are not recognized.
> 
>               o Only space and tab act as field  separators  when
>                 FS is set to a single space, newline does not.
> 
>               o The  synonym func for the keyword function is not
>                 recognized.
> 
>               o The operators ** and **= cannot be used in  place
>                 of ^ and ^=.
> 
>               o The fflush() function is not available.
> 
> These should be pretty easy to deal with.

Yes, well, if you read the man page carefully it says "following
additional restrictions", so no wonder they are easy to deal with. ;)

Stuff like the absence of gensub() may be a bit harder to deal with,
it's a damn tempting function to use while writing awk scripts. Some
have given in to the Dark Side :(

-- 
Antti Kantee <pooka@iki.fi>          v          Of course he runs NetBSD
http://www.iki.fi/pooka/             i            http://www.NetBSD.org/