Relay-Version: version B 2.10 5/3/83; site utzoo.UUCP
Posting-Version: version B 2.10.2 9/17/84; site opus.UUCP
Path: utzoo!linus!philabs!cmcl2!seismo!hao!nbires!opus!rcd
From: rcd@opus.UUCP (Dick Dunn)
Newsgroups: net.unix-wizards
Subject: Re: Is this correct action for the c compiler/preprocessor ??
Message-ID: <197@opus.UUCP>
Date: Mon, 4-Nov-85 03:02:23 EST
Article-I.D.: opus.197
Posted: Mon Nov  4 03:02:23 1985
Date-Received: Tue, 5-Nov-85 07:23:12 EST
References: <8510301207.AA27158@ucbvax.berkeley.edu> <270@cornell.UUCP>
Organization: NBI,Inc, Boulder CO
Lines: 20

> Most versions of pcc ignore stringness (``"'') when looking for tokens 
> for macro replacement.  Thus
> 	#define foo(a)	"This string contains a"
> expands the call ``foo(X)'' to
> 	"This string contains X"
> 
> K&R are silent on the lexical issues involved, so this cannot be considered
> incorrect...

Foo.  Come on, folks!  The relevant section of K&R is easy enough to
find--it's called "Token Replacement".  It's only half a page long and not
that hard to read.  Read along with me...

	Text inside a string or a character constant is not subject to
	replacement.

Get it?
-- 
Dick Dunn	{hao,ucbvax,allegra}!nbires!rcd		(303)444-5710 x3086
   ...Never attribute to malice what can be adequately explained by stupidity.