MUTEX_LOCK(&ab_op_map_mutex);
#endif
- val = ptable_fetch(ab_op_map, o);
+ val = (ab_op_info *)ptable_fetch(ab_op_map, o);
if (val) {
*oi = *val;
val = oi;
ab_map_store_locked(aPTBLMS_ (O), (PP), (B))
ab_op_info *oi;
- if (!(oi = ptable_fetch(ab_op_map, o))) {
- oi = PerlMemShared_malloc(sizeof *oi);
+ if (!(oi = (ab_op_info *)ptable_fetch(ab_op_map, o))) {
+ oi = (ab_op_info *)PerlMemShared_malloc(sizeof *oi);
ptable_map_store(ab_op_map, o, oi);
}
#ifndef ptable_new
STATIC ptable *ptable_new(pPTBLMS) {
#define ptable_new() ptable_new(aPTBLMS)
- ptable *t = PerlMemShared_malloc(sizeof *t);
+ ptable *t = (ptable *)PerlMemShared_malloc(sizeof *t);
t->max = 63;
t->items = 0;
- t->ary = PerlMemShared_calloc(t->max + 1, sizeof *t->ary);
+ t->ary = (ptable_ent **)PerlMemShared_calloc(t->max + 1, sizeof *t->ary);
return t;
}
#endif /* !ptable_new */
UV newsize = oldsize * 2;
UV i;
- ary = PerlMemShared_realloc(ary, newsize * sizeof(*ary));
+ ary = (ptable_ent **)PerlMemShared_realloc(ary, newsize * sizeof(*ary));
Zero(&ary[oldsize], newsize - oldsize, sizeof(*ary));
t->max = --newsize;
t->ary = ary;
ent->val = val;
} else if (val) {
const UV i = PTABLE_HASH(key) & t->max;
- ent = PerlMemShared_malloc(sizeof *ent);
+ ent = (ptable_ent *)PerlMemShared_malloc(sizeof *ent);
ent->key = key;
ent->val = val;
ent->next = t->ary[i];