minor mods
This commit is contained in:
parent
bfd6e2061f
commit
912e362f11
|
@ -72,7 +72,7 @@ new_idf(tg, size, cpy)
|
||||||
return pidf++;
|
return pidf++;
|
||||||
}
|
}
|
||||||
|
|
||||||
#ifdef DEBUG
|
#ifdef IDF_DEBUG
|
||||||
hash_stat()
|
hash_stat()
|
||||||
{
|
{
|
||||||
register int i;
|
register int i;
|
||||||
|
@ -84,13 +84,13 @@ hash_stat()
|
||||||
|
|
||||||
while (notch) {
|
while (notch) {
|
||||||
cnt++;
|
cnt++;
|
||||||
notch = notch->next;
|
notch = notch->id_next;
|
||||||
}
|
}
|
||||||
print("%d %d\n", i, cnt);
|
print("%d %d\n", i, cnt);
|
||||||
}
|
}
|
||||||
print("End hash table tally\n");
|
print("End hash table tally\n");
|
||||||
}
|
}
|
||||||
#endif DEBUG
|
#endif IDF_DEBUG
|
||||||
|
|
||||||
struct idf *
|
struct idf *
|
||||||
str2idf(tg, cpy)
|
str2idf(tg, cpy)
|
||||||
|
@ -135,12 +135,12 @@ str2idf(tg, cpy)
|
||||||
|
|
||||||
if (cmp == 0) return notch;
|
if (cmp == 0) return notch;
|
||||||
if (cmp < 0) break;
|
if (cmp < 0) break;
|
||||||
hook = ¬ch->next;
|
hook = ¬ch->id_next;
|
||||||
}
|
}
|
||||||
/* a new struct idf must be inserted at the hook */
|
/* a new struct idf must be inserted at the hook */
|
||||||
if (cpy < 0) return 0;
|
if (cpy < 0) return 0;
|
||||||
notch = new_idf(tg, size, cpy);
|
notch = new_idf(tg, size, cpy);
|
||||||
notch->next = *hook;
|
notch->id_next = *hook;
|
||||||
*hook = notch; /* hooked in */
|
*hook = notch; /* hooked in */
|
||||||
return notch;
|
return notch;
|
||||||
}
|
}
|
||||||
|
|
|
@ -14,7 +14,7 @@
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
struct idf {
|
struct idf {
|
||||||
struct idf *next; /* links idf-structures together */
|
struct idf *id_next; /* links idf-structures together */
|
||||||
char *id_text; /* string representing the name */
|
char *id_text; /* string representing the name */
|
||||||
#ifdef IDF_TYPE
|
#ifdef IDF_TYPE
|
||||||
IDF_TYPE IDF_NAME; /* user defined type and selector */
|
IDF_TYPE IDF_NAME; /* user defined type and selector */
|
||||||
|
|
Loading…
Reference in a new issue