[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: gcc or cc?



On Thu, Dec 10, 1998 at 09:46:31 +0100, Brederlow wrote:
> When considering poratibility and code cleaness, the only answere one
> can give to this question is "CC=cc".

What about CXX? What about the C9X standard when it's finished? Should we
have CC=c89 then?

> No sourcecode should rely on gcc or any of its extensions.

(If I were into scoring points, I'd say "come back when you've rewritten the
kernel")

I disagree. I prefer source code to be portable to non-gcc compilers, but
policy should not prescribe this.

> Look at g++, which is now replaced by eg++. The only thing that made the
> change difficult, where (and I think still are) some packages that use
> obscure stuff, that was g++ Vx.x.x specific (well, and some small bugs).

These versions of g++ had extensions for stuff that the then de facto C++
standard didn't have. Since then, the C++ standard has become a reality,
and g++ (especially the EGCS one) has been moving fast towards compliance
with it. This entailed the dropping of old extensions that were incompatible
with the new standard.

Standards should be used wherever feasible. But policy should not prescribe
adherence to language standards (de facto or de jure ones) when these aren't
sufficient to address realistic needs. 

Take libc for instance. By default, it tries to adhere to the standard,
POSIX, as much as feasible. But it has numerous often-used extensions beyond
it, which can be enabled in an easy fashion (an appropriate #define and
#include <features.h>).

Ray
-- 
Cyberspace, a final frontier. These are the voyages of my messages, 
on a lightspeed mission to explore strange new systems and to boldly go
where no data has gone before. 


Reply to: