home *** CD-ROM | disk | FTP | other *** search
/ NetNews Usenet Archive 1992 #16 / NN_1992_16.iso / spool / comp / lang / c / 11648 < prev    next >
Encoding:
Text File  |  1992-07-27  |  1.1 KB  |  34 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!news.th-darmstadt.de!backus.pu.informatik.th-darmstadt.de!wallmann
  3. From: wallmann@backus.pu.informatik.th-darmstadt.de (Natuerlich!)
  4. Subject: Re: Summary: Macro with variable number of arguments
  5. Sender: news@infoserver.th-darmstadt.de (The Usenet-News System)
  6. Message-ID: <1992Jul27.193601.25038@infoserver.th-darmstadt.de>
  7. Date: Mon, 27 Jul 1992 19:36:01 GMT
  8. References: <1992Jul25.140204.17746@fzi.de>
  9. Nntp-Posting-Host: backus.pu.informatik.th-darmstadt.de
  10. Organization: MSD software vault #9 @THD
  11. Keywords: macro arguments variable number summary
  12. Lines: 20
  13.  
  14. Here is a third solution, I -think- although I have never looked at it
  15. that this method is used in WEB (some Knuth-product):
  16.  
  17. #include <stdio.h>
  18.  
  19. #define _ ,
  20. #define OUT( x)  fprintf( stderr, x) 
  21.  
  22. main()
  23. {
  24.   OUT( "%c%c%c%c%c " _ 'H' _ 'a' _ 'l' _ 'l' _ 'o');
  25.   OUT( "%c%c%c%c\n" _ 'W' _ 'e' _ 'l' _ 't');
  26. }
  27.  
  28.  
  29. Nat!
  30. -- 
  31. Email: wallmann@backus.pu.informatik.th-darmstadt.de
  32.          "Bang that bit that doesn't bang"
  33. Waiting for the time when chips are measured in color.
  34.