Commit Graph

15 Commits

Author SHA1 Message Date
thorpej b4bbe79968 Use __GNUC_PREREQ__() for the GCC 4 test, too. 2006-08-21 16:58:29 +00:00
christos 93e48bdb1e __offsetof__ is a builtin, so we need __GNU_PREREQ 2006-08-21 15:31:18 +00:00
christos a162f659c6 gcc-3.3 does not have __offsetof__, but gcc-3.4 eems to require it:
From the redhat web page:

http://www.redhat.com/docs/manuals/enterprise/RHEL-4-Manual/gcc/offsetof.html

__offsetof__ (expression)
    is equivalent to the parenthesized expression, except that the
    expression is considered an integral constant expression even if
    it contains certain operators that are not normally permitted in
    an integral constant expression. Users should never use __offsetof__
    directly; the only valid use of __offsetof__ is to implement the
    offsetof macro in <stddef.h>.
2006-08-21 15:26:49 +00:00
christos a4f92031c6 g++-4 does not like &0->member, so we have to use the built-in offsetof().
g++-3 does not have a built-in offsetof(), but we cannot use the c version,
      otherwise we break with -Wold-style-cast.
Inspired by the DF version, but a bit different.
2006-08-21 15:02:23 +00:00
skd 21f8ec95d5 Use gcc's builtin function. This permits c++ compiliation of const
expressions using offsetof.  Boost-python relies on this, for example.
2006-08-21 14:09:43 +00:00
agc 039cc95684 Move UCB-licensed code from 4-clause to 3-clause licence.
Patches provided by Joel Baker in PR 22270, verified by myself.
2003-08-07 09:44:09 +00:00
tshiozak 004f47d81c u_long -> unsigned long in "offsetof" macro.
Using u_long causes <stddef.h> to undesirably depend on <sys/types.h> .
BTW: Why is the cast needed?
2000-11-10 06:35:45 +00:00
christos 406d83685a de-lint 2000-07-06 00:51:36 +00:00
kleink 1bba558e50 Move <null.h> to <sys/null.h> for the purpose of avoiding conflicts due to
std C headers including it, and a kernel module written in C++ would benfit
as well.
2000-01-10 16:58:38 +00:00
kleink c07f17e8d9 For the benefit of G++'s null pointer constant implementation, #define NULL
as __null with egcs 1.0 (GCC 2.90) and above.  As several headers are affected
by this change, move the definition into a new header file, <null.h>, to ease
maintenance.
1999-12-22 21:26:15 +00:00
perry 4ab34663db merge lite-2 sccs id, but as per jt, don't switch to using lite-2 rune_t's 1998-02-02 17:13:49 +00:00
cgd 4d2cbfce0a new RCS ID format. 1994-10-26 00:55:40 +00:00
cgd 2922de7461 add _BSD's to ansi types 1994-05-21 09:41:59 +00:00
mycroft e9d867ef50 Add RCS identifiers. 1993-08-01 17:54:45 +00:00
cgd 61f282557f initial import of 386bsd-0.1 sources 1993-03-21 09:45:37 +00:00