/dev/stdin

Brandon S. Allbery allbery at ncoast.UUCP
Thu Jul 14 10:16:46 AEST 1988


As quoted from <12327 at mimsy.UUCP> by chris at mimsy.UUCP (Chris Torek):
+---------------
| >In article <16305 at brl-adm.ARPA> rbj at cmr.icst.nbs.gov (Root Boy Jim) suggests:
| >>Another (mis?)use is to compile programs from stdin. First, we do
| >>`ln -s /dev/stdin x.c', then `cc -c x.c'. ...
| 
| In article <8220 at ncoast.UUCP> allbery at ncoast.UUCP (Brandon S. Allbery) writes:
| >Would this work?  I was under the impression that the C compiler made
| >multiple passes over the source ....
| 
| Some do; but the first will be /lib/cpp, with output sent to a temp
| file, in this case.  I suppose someone might run the preprocessor
| twice. . . .
+---------------

May I remind everyone that nowhere does it state that Unix cc *must* have a
separate /lib/cpp?  Xenix System V/386 has /lib/cpp, but Microsoft cc *does*
*not* *use* *it* -- for proof, try your favorite Reiserisms under Xenix.  Or
*any* #define'd macro which depends on /lib/cpp outputting text instead of
tokens.  (Microsoft may have plans to change this, or may have already done
so in recent versions of SCO Xenix.  But the point still remains that there's
no law requiring /lib/cpp to be separate from the actual compiler.)
-- 
Brandon S. Allbery, uunet!marque!ncoast!allbery			DELPHI: ALLBERY
	    For comp.sources.misc send mail to ncoast!sources-misc



More information about the Comp.unix.wizards mailing list