Path: utzoo!utgpu!news-server.csri.toronto.edu!cs.utexas.edu!uunet!taumet!steve From: steve@taumet.com (Stephen Clamage) Newsgroups: comp.lang.c++ Subject: Re: best extension for C++ files Message-ID: <451@taumet.com> Date: 11 Sep 90 15:41:23 GMT References: <907@zinn.MV.COM> <1845@cs.rit.edu> <3358@stl.stc.co.uk> <1990Sep08.094000.10269@virtech.uucp> <144@tdatirv.UUCP> Organization: Taumetric Corporation, San Diego Lines: 24 sarima@tdatirv.UUCP (Stanley Friesen) writes: >In article <1990Sep08.094000.10269@virtech.uucp> rdg@virtech.uucp (Roger D. Gough) writes: >>Maybe this would simply add to the confusion, but why not just use '.c' >>and '.h', and let whoever needs to know look in the makefile (or equivalent) >>to see how CC is defined, etc. >The big problem with this is when one needs to *mix* C and C++ sources in a >single project (as, for instance, in converting from C to C++ on an existing >product). In this case the *single* makefile needs to be able to tell for >each source file whether it is C or C++ to call the right compiler. If you include a build line for each file (or for each file of either C or C++ at minimum), it doesn't matter that the file endings are the same. This is not as onerous as it sounds, since I find for projects of any size, the set of header-file dependencies for different source files is different, and thus requires at least a dependency line for most files. The nice thing about text editors is that it is simple to add the lines to the make file -- and in any event, you only have to do it once! -- Steve Clamage, TauMetric Corp, steve@taumet.com