~drizzle-trunk/drizzle/development

« back to all changes in this revision

Viewing changes to mysys/my_bitmap.h

  • Committer: Brian Aker
  • Date: 2009-02-21 00:18:15 UTC
  • Revision ID: brian@tangent.org-20090221001815-x20e8h71e984lvs1
Completion (?) of uint conversion.

Show diffs side-by-side

added added

removed removed

Lines of Context:
16
16
#ifndef _my_bitmap_h_
17
17
#define _my_bitmap_h_
18
18
 
19
 
#define MY_BIT_NONE (~(uint) 0)
 
19
#define MY_BIT_NONE (~(uint32_t) 0)
20
20
 
21
21
#include <mystrings/m_string.h>
22
22
 
101
101
                                  ^= (1 << ((BIT) & 7)))
102
102
#define _bitmap_clear_bit(MAP, BIT) (((unsigned char*)(MAP)->bitmap)[(BIT) / 8] \
103
103
                                  &= ~ (1 << ((BIT) & 7)))
104
 
#define _bitmap_is_set(MAP, BIT) (uint) (((unsigned char*)(MAP)->bitmap)[(BIT) / 8] \
 
104
#define _bitmap_is_set(MAP, BIT) (uint32_t) (((unsigned char*)(MAP)->bitmap)[(BIT) / 8] \
105
105
                                         & (1 << ((BIT) & 7)))
106
106
/*
107
107
  NEVER use an increment/decrement operator with the 'bit' argument.