src/hash_map.c

changeset 668
d7129285ac32
parent 665
c4041b07165e
child 669
dce9b8450656
equal deleted inserted replaced
667:2f88a7c13a28 668:d7129285ac32
430 // initialize base members 430 // initialize base members
431 map->base.store_pointers = false; 431 map->base.store_pointers = false;
432 map->base.cl = &cx_hash_map_class; 432 map->base.cl = &cx_hash_map_class;
433 map->base.allocator = allocator; 433 map->base.allocator = allocator;
434 map->base.size = 0; 434 map->base.size = 0;
435 map->base.itemsize = itemsize; 435
436 if (itemsize > 0) {
437 map->base.itemsize = itemsize;
438 } else {
439 cxMapStorePointers((CxMap *) map);
440 }
436 441
437 return (CxMap *) map; 442 return (CxMap *) map;
438 } 443 }
439 444
440 int cxMapRehash(CxMap *map) { 445 int cxMapRehash(CxMap *map) {

mercurial