]> Cypherpunks repositories - gostls13.git/commitdiff
runtime: Change size of map iter offset so 32-bit version compiles cleanly.
authorKeith Randall <khr@golang.org>
Tue, 14 Jan 2014 21:46:22 +0000 (13:46 -0800)
committerKeith Randall <khr@golang.org>
Tue, 14 Jan 2014 21:46:22 +0000 (13:46 -0800)
R=golang-codereviews, minux.ma
CC=golang-codereviews
https://golang.org/cl/52310043

src/pkg/runtime/hashmap.c

index c359e2a14dcbc123f0cdd7bddcf6d1798a102f23..f01779e23dbda2cd07be10af8ce36960b2c2f876 100644 (file)
@@ -746,7 +746,7 @@ struct hash_iter
        byte *buckets; // bucket ptr at hash_iter initialization time
        struct Bucket *bptr; // current bucket
 
-       uint32 offset; // intra-bucket offset to start from during iteration
+       uint8 offset; // intra-bucket offset to start from during iteration (should be big enough to hold BUCKETSIZE-1)
        bool done;
 
        // state of table at time iterator is initialized