From mboxrd@z Thu Jan 1 00:00:00 1970 X-Spam-Checker-Version: SpamAssassin 3.4.4 (2020-01-24) on polar.synack.me X-Spam-Level: X-Spam-Status: No, score=-1.9 required=5.0 tests=BAYES_00 autolearn=ham autolearn_force=no version=3.4.4 X-Google-Language: ENGLISH,ASCII-7-bit X-Google-Thread: 103376,4c019ad9cc913bbe X-Google-Attributes: gid103376,public X-Google-ArrivalTime: 2002-09-16 09:34:30 PST Path: archiver1.google.com!news1.google.com!newsfeed.stanford.edu!news.ems.psu.edu!news.cse.psu.edu!uwm.edu!rpi!usc.edu!newspeer.cts.com!galanthis.cts.com!127.0.0.1.MISMATCH!not-for-mail Sender: kst@king.cts.com Newsgroups: comp.lang.ada Subject: Re: The Dreaded "Missing Subunits" References: <1b585154.0209121449.ef12609@posting.google.com> <3D819EE7.3A69E5EB@praxis-cs.co.uk> <4519e058.0209160548.461cef27@posting.google.com> From: Keith Thompson Date: 16 Sep 2002 09:33:31 -0700 Message-ID: X-Newsreader: Gnus v5.7/Emacs 20.7 NNTP-Posting-Host: 209.68.192.180 X-Trace: 1032194011 nntp.cts.com 20549 209.68.192.180 Xref: archiver1.google.com comp.lang.ada:29034 Date: 2002-09-16T09:33:31-07:00 List-Id: dennison@telepath.com (Ted Dennison) writes: [...] > And of course most folks feel that C++ should have its own extensions, > but there is little agreement on what they should be. ".cpp" seems > common, but I've also seen ".C" and ".cc". The extension ".c" is > sometimes used to mean code that is purposely C compatable, while > sometimes its used for C++-only files. For headers I've seen > personally or seen suggested ".h", ".hpp", ".d", "..c", ".hh", and > ".icc" (for inline header files). The C++ standard itself specifies > that quite a few header files have no extension at all! Actually, it specifies that quite a few *headers*, not necessarily header files, have no extension. There's no requirement that the predefined headers be implemented as files; even if they are, there's no required correlation between the names used in the "#include" directive and the actual names of the files. > Of course no matter what you use, the compiler won't care a bit, and > will happily include a ".cpp" or compile a ".hpp", if you tell it to > and the syntax passes. At least for C, there's no language requirement for any particular filename extensions, but there's a very strong convention that header files are *.h and other source files are *.c. (No, that convention isn't always honored, but I rarely see exceptions.) The source file naming situation for C++ and Ada actually seems pretty similar. The C and Ada file naming conventions are also pretty similar, except that C's conventions are more consistent. -- Keith Thompson (The_Other_Keith) kst@cts.com San Diego Supercomputer Center <*> Schroedinger does Shakespeare: "To be *and* not to be"