This commit is contained in:
hyung-hwan 2008-03-23 06:09:35 +00:00
parent 3de3860163
commit a04e00132c
2 changed files with 11 additions and 10 deletions

View File

@ -1,5 +1,5 @@
/*
* $Id: val.c 155 2008-03-22 06:47:27Z baconevi $
* $Id: val.c 156 2008-03-22 12:09:35Z baconevi $
*
* {License}
*/
@ -206,7 +206,7 @@ ase_awk_val_t* ase_awk_makerealval (ase_awk_run_t* run, ase_real_t v)
c->next = run->vmgr.rchunk;
/*run->vmgr.rchunk = c;*/
run->vmgr.ichunk = (ase_awk_val_chunk_t*)c;
run->vmgr.rchunk = (ase_awk_val_chunk_t*)c;
/*
x = (ase_awk_val_real_t*)(c + 1);
@ -1066,9 +1066,11 @@ static int print_pair (ase_pair_t* pair, void* arg)
{
ase_awk_run_t* run = (ase_awk_run_t*)arg;
DPRINTF (DCUSTOM, ASE_T(" %s=>"), pair->key);
DPRINTF (DCUSTOM, ASE_T(" %.*s=>"),
(int)ASE_PAIR_KEYLEN(pair), ASE_PAIR_KEYPTR(pair));
ase_awk_dprintval ((ase_awk_run_t*)arg, pair->val);
DPRINTF (DCUSTOM, ASE_T(" "));
return 0;
}

View File

@ -1,5 +1,5 @@
/*
* $Id: map.c 116 2008-03-03 11:15:37Z baconevi $
* $Id: map.c 156 2008-03-22 12:09:35Z baconevi $
*
* {License}
*/
@ -17,6 +17,7 @@ static int rehash (ase_map_t* map);
ASE_FREE ((map)->mmgr, pair); \
} while (0)
/*
#define RECYCLE_PAIR(map,pair) \
do { \
if ((map)->freeval != ASE_NULL) \
@ -24,6 +25,7 @@ static int rehash (ase_map_t* map);
(pair)->next = (map)->fp; \
(map)->fp = (pair); \
} while (0)
*/
ase_map_t* ase_map_open (
void* owner, ase_size_t capa, unsigned int factor,
@ -247,8 +249,7 @@ ase_pair_t* ase_map_getpair (
return pair;
}
ase_pair_t* ase_map_setpair (
ase_map_t* map, ase_pair_t* pair, void* val)
ase_pair_t* ase_map_setpair (ase_map_t* map, ase_pair_t* pair, void* val)
{
/* use this function with care */
if (ASE_PAIR_VAL(pair) == val)
@ -312,8 +313,7 @@ int ase_map_remove (
return -1;
}
int ase_map_walk (ase_map_t* map,
int (*walker) (ase_pair_t*,void*), void* arg)
int ase_map_walk (ase_map_t* map, int (*walker) (ase_pair_t*,void*), void* arg)
{
ase_size_t i;
ase_pair_t* pair, * next;
@ -333,8 +333,7 @@ int ase_map_walk (ase_map_t* map,
return 0;
}
ase_pair_t* ase_map_getfirstpair (
ase_map_t* map, ase_size_t* buckno)
ase_pair_t* ase_map_getfirstpair (ase_map_t* map, ase_size_t* buckno)
{
ase_size_t i;
ase_pair_t* pair;