CTRL(x)
    Joseph S. D. Yao 
    jsdy at hadron.UUCP
       
    Thu Nov 13 14:46:44 AEST 1986
    
    
  
In article <1319 at sunybcs.UUCP> colonel at sunybcs.UUCP (Col. G. L. Sicherman) writes:
>) >But. . .is there a way to write an ANSI cpp version of
>) >        #define CTRL(c)
>		   ...  What's wrong with this old trick?
>	#define Q "
>	#define CTRL(z) (Q z "[1]^0100)
The XOR, (x^0100), will not generally work.  Use (x&037).  Also,
there was some concern that "..."[x] will not work where a
constant is required, such as in a case statement.
-- 
	Joe Yao		hadron!jsdy at seismo.{CSS.GOV,ARPA,UUCP}
			jsdy at hadron.COM (not yet domainised)
    
    
More information about the Comp.lang.c
mailing list