home *** CD-ROM | disk | FTP | other *** search
/ NetNews Usenet Archive 1992 #20 / NN_1992_20.iso / spool / comp / lang / c / 13390 < prev    next >
Encoding:
Text File  |  1992-09-09  |  1.3 KB  |  31 lines

  1. Newsgroups: comp.lang.c
  2. Path: sparky!uunet!mcsun!Germany.EU.net!news.netmbx.de!zrz.tu-berlin.de!math.fu-berlin.de!informatik.tu-muenchen.de!hphalle6!behrenss
  3. From: behrenss@Informatik.TU-Muenchen.DE (Soenke Behrens)
  4. Subject: Re: Print #define
  5. References: <1992Aug26.124652.9509@alw.nih.gov> <DeqcqB1w165w@bluemoon.rn.com> <1992Sep9.152715.8286@us-es.sel.de>
  6. Sender: news@Informatik.TU-Muenchen.DE (USENET Newssystem)
  7. Organization: Technische Universitaet Muenchen, Germany
  8. Date: Wed, 9 Sep 1992 15:53:44 GMT
  9. Message-ID: <behrenss.716054024@hphalle6>
  10. Lines: 19
  11.  
  12. lisa@us-es.sel.de (Lisa Goulet) writes:
  13.  
  14. >In K&R C, is there a way to print a preprocessor variable?
  15. >e.g.  With the following define 
  16. >        #define Architecture hp300
  17. >      to be able to print the "hp300" part.
  18.  
  19. Not that I could think of a way to do that. You would need to get
  20. the macro into a character string, and CPP doesn't expand macros inside
  21. of character strings.
  22.  
  23. Not that I could think of any necessity to do such a thing, either :)
  24.  
  25. Soenke
  26. -- 
  27. ===========================================================================
  28. More than silver, more than gold, I need   !    behrenss@informatik.
  29. electricity. I need it for my dreams.      !    tu-muenchen.de
  30. (RACTER)                                   !  FIDO: 2:246/13 Soenke Behrens
  31.