#define kinda stuff

Ray Trent trent at cit-vax.Caltech.Edu
Fri Apr 11 09:38:29 AEST 1986


[this space for rent]

In article <1458 at cwruecmp.UUCP> ryan at cwruecmp.UUCP (Ryan McGuire) writes:
>    Here's what I wanna do:
>
>#define (-: /*
>#define :-) */

I don't know about your C compiler, but MY prepreocessor barfs at
having a macro named "(-:", so I would imagine that even if you get 
/* to (not) expand correctly, this construct will not be portable.

I quote from K&R:

A compiler-control line of the form
	#define identifier token-string
...causes the preprocessor to...(Appendix A, ss 12.1)

and:

Appendix A.2.2: Identifiers
	An identifier is a sequence of letters and digits; the
	first character must be a letter....

-- 
					../ray\..
				(trent at csvax.caltech.edu)
"The above is someone else's opinion only at great coincidence"



More information about the Comp.unix.wizards mailing list