Path: utzoo!news-server.csri.toronto.edu!cs.utexas.edu!sun-barr!newstop!texsun!convex!grogers From: grogers@convex.com (Geoffrey Rogers) Newsgroups: comp.lang.c Subject: Re: trouble with macro`s Message-ID: <1991Mar17.174114.15994@convex.com> Date: 17 Mar 91 17:41:14 GMT References: <27489@netcom.COM> <1991Mar16.213446.20392@NCoast.ORG> Sender: news@convex.com (news access account) Organization: Convex Computer Corporation, Richardson, Tx. Lines: 22 Nntp-Posting-Host: mozart.convex.com In article <1991Mar16.213446.20392@NCoast.ORG> catfood@NCoast.ORG (Mark W. Schumann) writes: >You could try > > #dfine name2(a,b) a/**/b > >This might work, but I am not sure whether K&R compilers strip >comments before or after evaluating macros. Try it. Yes this works on some not all pre-ANSI cpp. Another to do the same thing is: #define name2(a,b) name2_(a)b #define name2_(a) a this also works. But I do not know if it works on all pre-ANSI cpp. +------------------------------------+---------------------------------+ | Geoffrey C. Rogers | "Whose brain did you get?" | | grogers@convex.com | "Abbie Normal!" | | {sun,uunet,uiucdcs}!convex!grogers | | +------------------------------------+---------------------------------+