🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: comp.std.c++
Article #3622

Re: #endif //

#3622
From: Zefram
Date: Fri, 08 Mar 1996 17:07
19 lines
1698 bytes
Michael Cook  <mcook@cognex.com> wrote:
>Is it legal to have //-style comments within a preprocessor directive?  If so,
>that'd mean C++ compilers would be precluded from using ISO C preprocessors.

That is correct.  Comments are converted into spaces before
preprocessing occurs.  In practice, it is common for a single
preprocessor program to have two modes of operation, one in which //
starts a comment and one in which it does not.  That preprocessor can
then be used for both languages.  (Actually other options are needed
too, controlling which digraphs are recognised.)

-zefram
---
[ comp.std.c++ is moderated.  To submit articles: Try just posting with your 
                newsreader.  If that fails, use mailto:std-c++@ncar.ucar.edu
  comp.std.c++ FAQ: http://reality.sgi.com/austern/std-c++/faq.html
  Moderation policy: http://reality.sgi.com/austern/std-c++/policy.html
  Comments? mailto:std-c++-request@ncar.ucar.edu 
]
Technical Details
Message-ID: <10625.199603080914@diamond.dcs.warwick.ac.uk>
Path: arc1-ca.pugleaf.net!chronicle.mti.sgi.com!austern
References: <r4lolec6xs.fsf@erawan.cognex.com>

Show Full Headers
Complete Article Headers
Path: arc1-ca.pugleaf.net!chronicle.mti.sgi.com!austern
From: A.Main@dcs.warwick.ac.uk (Zefram)
Newsgroups: comp.std.c++
Subject: Re: #endif //
Date: 08 Mar 1996 09:07:52 PST
Organization: Department of Computer Science, Warwick University, England
Approved: austern@isolde.mti.sgi.com
Message-ID: <10625.199603080914@diamond.dcs.warwick.ac.uk>
References: <r4lolec6xs.fsf@erawan.cognex.com>
NNTP-Posting-Host: isolde.mti.sgi.com
X-Original-Date: Fri, 8 Mar 1996 09:14:43 GMT
X-Stardate: [-31]7166.90
X-Us-Congress: Moronic fuckers
X-Auth: PGPMoose V1.1 PGP comp.std.c++
 iQBVAwUBMUBpdky4NqrwXLNJAQFgnQH/ZiBon5zHgIah9kiiv5/gSZhvcFXz82vO
 0a7nWh25OlZzV8X6yCXhd7P9QMZ8ya5859oQnriZgSyuIDmVXX0CqQ==
 =ncTY
Originator: austern@isolde.mti.sgi.com