Relay-Version: version B 2.10 5/3/83; site utzoo.UUCP
Posting-Version: version B 2.10.2 (Tek) 9/28/84 based on 9/17/84; site zeus.UUCP
Path: utzoo!watmath!clyde!burl!ulysses!allegra!mit-eddie!genrad!decvax!tektronix!teklds!zeus!bobr
From: bobr@zeus.UUCP (Robert Reed)
Newsgroups: net.bugs.v7,net.unix-wizards
Subject: Re: awk vs. regular expressions starting with equal sign
Message-ID: <433@zeus.UUCP>
Date: Fri, 14-Dec-84 18:56:12 EST
Article-I.D.: zeus.433
Posted: Fri Dec 14 18:56:12 1984
Date-Received: Mon, 17-Dec-84 02:36:27 EST
References: <4770@utzoo.UUCP>
Organization: Tektronix, Beaverton OR
Lines: 15
Xref: watmath net.bugs.v7:179 net.unix-wizards:11079

> There is a fundamental lexical ambiguity in awk:  when you see "/=",
> is this the divide-by-and-assign operator, or the start of a regular
> expression which happens to begin with an equal sign? 
>
> 				Henry Spencer @ U of Toronto Zoology
> 				{allegra,ihnp4,linus,decvax}!utzoo!henry

You can easily get around it by escaping it, such as

	awk '/\= / {...}' ...

I tried this on our 4.2BSD system and it seems to work just fine.

-- 
Robert Reed, Logic Design Systems Division, tektronix!teklds!bobr