When do you use "if ( a = b )"?

Rob McMahon cudcv at warwick.ac.uk
Fri Apr 12 01:01:50 AEST 1991


In article <571 at bria> uunet!bria!mike writes:
>Is there a flavor of preprocessor that unwinds *just* the #define's, and
>leaves the rest alone?

Yup, it's called `scpp'.  I'm sure I got it off comp.sources.all (or was it
mod.sources ...):

/*
 * scpp.c - main processing for the selective C preprocessor, scpp.
 *
 * Copyright (c) 1985 by
 * Tektronix, Incorporated Beaverton, Oregon 97077
 * All rights reserved.
 *
 * Permission is hereby granted for personal, non-commercial
 * reproduction and use of this program, provided that this
 * notice and all copyright notices are included in any copy.
 */

DESCRIPTION
     Scpp concatenates the input files (or reads standard-in,  if
     no  file  is given), interprets all references to given mac-
     ros, leaving the rest of the file(s) unaltered, then  writes
     the  result to standard-out.  It is helpful in removing con-
     ditionally compiled code or misleading macros from a file.

AUTHOR
     Brad Needham, Tektronix, Inc.

Occasionally it's very useful.

Cheers,

Rob
-- 
UUCP:   ...!mcsun!ukc!warwick!cudcv	PHONE:  +44 203 523037
JANET:  cudcv at uk.ac.warwick             INET:   cudcv at warwick.ac.uk
Rob McMahon, Computing Services, Warwick University, Coventry CV4 7AL, England



More information about the Comp.lang.c mailing list