Commit 63b6f9ea by Andrew Pinski Committed by Andrew Pinski

re PR libobjc/12035 (Patch for libobjc/gc.c that fixes compilation error of…

re PR libobjc/12035 (Patch for libobjc/gc.c that fixes compilation error of Objective-C with garbage collector enabled)

2004-12-20  Andrew Pinski  <pinskia@physics.uc.edu>

        PR libobjc/12035
        * gc.c: Remove definition of LOGWL, modWORDSZ, and divWORDSZ since
        they are not used.  Include limits.h and stdlib.h.

From-SVN: r92437
parent 8ff61ea7
2004-12-20 Andrew Pinski <pinskia@physics.uc.edu>
PR libobjc/12035
* gc.c: Remove definition of LOGWL, modWORDSZ, and divWORDSZ since
they are not used. Include limits.h and stdlib.h.
2004-12-12 Alexander Malmberg <alexander@malmberg.org> 2004-12-12 Alexander Malmberg <alexander@malmberg.org>
* selector.c (__objc_init_selector_tables): Add missing void to * selector.c (__objc_init_selector_tables): Add missing void to
......
...@@ -31,26 +31,17 @@ Boston, MA 02111-1307, USA. */ ...@@ -31,26 +31,17 @@ Boston, MA 02111-1307, USA. */
#include <assert.h> #include <assert.h>
#include <string.h> #include <string.h>
#include <stdlib.h>
#if OBJC_WITH_GC #if OBJC_WITH_GC
#include <gc.h> #include <gc.h>
#include <limits.h>
/* gc_typed.h uses the following but doesn't declare them */ /* gc_typed.h uses the following but doesn't declare them */
typedef GC_word word; typedef GC_word word;
typedef GC_signed_word signed_word; typedef GC_signed_word signed_word;
#define BITS_PER_WORD (CHAR_BIT * sizeof (word))
#if BITS_PER_WORD == 32
# define LOGWL 5
# define modWORDSZ(n) ((n) & 0x1f) /* n mod size of word */
#endif
#if BITS_PER_WORD == 64
# define LOGWL 6
# define modWORDSZ(n) ((n) & 0x3f) /* n mod size of word */
#endif
#define divWORDSZ(n) ((n) >> LOGWL) /* divide n by size of word */
#include <gc_typed.h> #include <gc_typed.h>
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment