Date: Sun, 16 Apr 1995 10:17:14 +1000 From: Bruce Evans <bde@zeta.org.au> To: freebsd-hackers@FreeBSD.org, j@uriah.heep.sax.de Subject: Re: 90's compilers Message-ID: <199504160017.KAA09761@godzilla.zeta.org.au>
next in thread | raw e-mail | index | archive | help
>> As I feel that "protection" for old and braindead compilers at the
>> cost of higher obfuscation is no longer worth it.
>Same opinion for me. And once i had to tweak that fancy boot code,
>the non-declarations bothered me too much, so i've added them without
>those funny _P()'s.
_P() doesn't bother me at all (if it is correctly spelled and punctuated
as __P(()) :-). What do you think of the other klupges in <sys/cdefs.h>?
__dead* and __pure* can't be avoided.
>The _P()'s cannot go from the standard header files, however. They
>are required there for old programs that need to be compiled with
>-traditional (since the `porter' is too lazy to resolve the conflicts
>like ``mktemp("foooXXX")'').
Nope, prototypes work with `gcc -traditional'. They are there for
other K&R1 compilers. They don't help much because they are not used
in a few headers.
K&R1 and non-gcc compilers fail to compile most of our sources for
the more fundament reason that <sys/types.h> declares things as having
the bogus type `long long'. `gcc -pedantic -Werror' fails too. The
latter problem can be fixed by using __attribute((mode(DI))) as was
done in the 1.1.5 <sys/types.h>. I have problems parsing this and
so does gcc :-). gcc dumps core for
int foo(void) __attribute((mode(DI))) { return 1; }
__attribute(()) seems to work better in typedefs:
typedef int quad_t __attribute((mode(DI)));
quad_t foo(void) { return 1; }
Bruce
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?199504160017.KAA09761>
