Mail Archives: djgpp/1997/06/24/21:54:49
Liam wrote:
> Can't it tell the difference between C and C++ code
> with out relying on the extension of a file?
Some compilers do this, but they tend to be more trouble than they're
worth. Some of them even have options to _always_ compile as C++, which
generates even bigger problems, as C++ is _not_ a proper superset of C.
If you don't want to use a C++ extension (.cc, .cpp), then you can use the
-x command line parameter to explicitly choose the language. However,
this seems an awfully strange thing to want to do, especially since it's
not as if using the above extensions to mean C++ source files is unusual.
--
Erik Max Francis, &tSftDotIotE / email / max AT alcyone DOT com
Alcyone Systems / web / http://www.alcyone.com/max/
San Jose, California, United States / icbm / 37 20 07 N 121 53 38 W
\
"Covenants without the sword / are but words."
/ Camden
- Raw text -