home *** CD-ROM | disk | FTP | other *** search
/ NetNews Usenet Archive 1992 #27 / NN_1992_27.iso / spool / comp / lang / function / 1383 < prev    next >
Encoding:
Internet Message Format  |  1992-11-17  |  1.4 KB

  1. Path: sparky!uunet!portal!lll-winken!diego.llnl.gov!miller
  2. From: miller@diego.llnl.gov (Patrick Miller)
  3. Newsgroups: comp.lang.functional
  4. Subject: Re: Including files from ml-lex and -yacc
  5. Keywords: ml-lex ml-yacc sml
  6. Message-ID: <141745@lll-winken.LLNL.GOV>
  7. Date: 17 Nov 92 16:57:06 GMT
  8. References: <1992Nov10.142821.8095@daimi.aau.dk> <farrell.721895635@coral>
  9. Sender: usenet@lll-winken.LLNL.GOV
  10. Organization: Lawrence Livermore National Laboratory
  11. Lines: 21
  12. Nntp-Posting-Host: diego.llnl.gov
  13.  
  14. In article <farrell.721895635@coral>, farrell@coral.cs.jcu.edu.au (John Farrell) writes:
  15. |> >directive %Include <filename> meaning that the file <filename> is to
  16. |> ...
  17.  
  18. |>   I thought the standard way to do this was to use the same compiler
  19. |> directives as C does, then use the C preprocessor :-). It's a hack, I know,
  20. |> but it provides a well-known set of functions at very low cost.
  21.  
  22. One has to be careful how this is done.  Remember that C preprocessors
  23. have varying awareness of comment characters, etc...   The following
  24. was causing the Sisal preprocessor (a CPP hack as described) to bomb.
  25. The % is a comment character.
  26.  
  27.         for initial            % Can't do it too much
  28.  
  29. The problem was that Sisal uses Mark-to-endofline comments.  The CPP
  30. was getting confused over the single quote without matching end quote!
  31.  
  32. -- 
  33. Pat Miller                            I have many opinions, but they
  34. patmiller@llnl.gov                      generally aren't humble ones
  35.