aboutsummaryrefslogtreecommitdiffstats
path: root/qmljs_objects.h
diff options
context:
space:
mode:
authorLars Knoll <lars.knoll@digia.com>2012-11-29 22:25:21 +0100
committerErik Verbruggen <erik.verbruggen@digia.com>2012-11-30 10:03:21 +0100
commitf00cf7cfae716f5e5af2d0952c3a822744977811 (patch)
tree57687d378299134db8c41cb0d36da94615c86242 /qmljs_objects.h
parenta14e7549c4a3faece3474f059b2d04005cfc7cbf (diff)
Give primeIds the amount of bits it requires
Also mark the prime number array as const Change-Id: Ieae3e5d13decb0edf0d086780b323a12351a55d8 Reviewed-by: Erik Verbruggen <erik.verbruggen@digia.com>
Diffstat (limited to 'qmljs_objects.h')
-rw-r--r--qmljs_objects.h6
1 files changed, 3 insertions, 3 deletions
diff --git a/qmljs_objects.h b/qmljs_objects.h
index 4e0af583d1..a35d59f447 100644
--- a/qmljs_objects.h
+++ b/qmljs_objects.h
@@ -373,7 +373,7 @@ private:
inline int nextPrime()
{
// IMPORTANT: do not add more primes without checking if _primeIdx needs more bits!
- static int primes[] = {
+ static const int primes[] = {
11, 23, 47, 97, 197, 397, 797, 1597, 3203, 6421, 12853, 25717, 51437, 102877
};
@@ -390,8 +390,8 @@ private:
PropertyTableEntry *_freeList;
int _propertyCount;
int _bucketCount;
- int _primeIdx: 4;
- int _allocated: 28;
+ int _primeIdx: 5;
+ int _allocated: 27;
};
struct Object {