summaryrefslogtreecommitdiffstats
path: root/crawl-ref/source/bitary.h
diff options
context:
space:
mode:
authorAdam Borowski <kilobyte@angband.pl>2012-07-26 14:22:38 +0200
committerAdam Borowski <kilobyte@angband.pl>2012-07-26 14:22:38 +0200
commit705162b1193ce341608cbbe7017119e366760a1a (patch)
tree032e8af6f1479313338a0c8aae45f43fc9181215 /crawl-ref/source/bitary.h
parent44f40dd5f9fe2e775a80616ca2f03e375c120bed (diff)
downloadcrawl-ref-705162b1193ce341608cbbe7017119e366760a1a.tar.gz
crawl-ref-705162b1193ce341608cbbe7017119e366760a1a.zip
Rename FixedBitArray to FixedBitVector.
Diffstat (limited to 'crawl-ref/source/bitary.h')
-rw-r--r--crawl-ref/source/bitary.h12
1 files changed, 6 insertions, 6 deletions
diff --git a/crawl-ref/source/bitary.h b/crawl-ref/source/bitary.h
index b01f9ddff5..98a33bef6f 100644
--- a/crawl-ref/source/bitary.h
+++ b/crawl-ref/source/bitary.h
@@ -34,7 +34,7 @@ protected:
#define LONGSIZE (sizeof(unsigned long)*8)
-template <unsigned int SIZE> class FixedBitArray
+template <unsigned int SIZE> class FixedBitVector
{
protected:
unsigned long data[(SIZE + LONGSIZE - 1) / LONGSIZE];
@@ -45,7 +45,7 @@ public:
data[i] = 0;
}
- FixedBitArray()
+ FixedBitVector()
{
reset();
}
@@ -55,7 +55,7 @@ public:
#ifdef ASSERTS
// printed as signed, as in FixedVector
if (i >= SIZE)
- die("bit array range error: %d / %u", (int)i, SIZE);
+ die("bit vector range error: %d / %u", (int)i, SIZE);
#endif
return data[i / LONGSIZE] & 1UL << i % LONGSIZE;
}
@@ -69,7 +69,7 @@ public:
{
#ifdef ASSERTS
if (i >= SIZE)
- die("bit array range error: %d / %u", (int)i, SIZE);
+ die("bit vector range error: %d / %u", (int)i, SIZE);
#endif
if (value)
data[i / LONGSIZE] |= 1UL << i % LONGSIZE;
@@ -77,14 +77,14 @@ public:
data[i / LONGSIZE] &= ~(1UL << i % LONGSIZE);
}
- inline FixedBitArray<SIZE>& operator|=(const FixedBitArray<SIZE>&x)
+ inline FixedBitVector<SIZE>& operator|=(const FixedBitVector<SIZE>&x)
{
for (unsigned int i = 0; i < ARRAYSZ(data); i++)
data[i] |= x.data[i];
return *this;
}
- inline FixedBitArray<SIZE>& operator&=(const FixedBitArray<SIZE>&x)
+ inline FixedBitVector<SIZE>& operator&=(const FixedBitVector<SIZE>&x)
{
for (unsigned int i = 0; i < ARRAYSZ(data); i++)
data[i] &= x.data[i];