dtdocbook: Change to ANSI function definitions
This commit is contained in:
@@ -99,12 +99,13 @@ static Tcl_HashEntry * OneWordCreate _ANSI_ARGS_((Tcl_HashTable *tablePtr,
|
||||
*/
|
||||
|
||||
void
|
||||
Tcl_InitHashTable(tablePtr, keyType)
|
||||
register Tcl_HashTable *tablePtr; /* Pointer to table record, which
|
||||
Tcl_InitHashTable(
|
||||
register Tcl_HashTable *tablePtr, /* Pointer to table record, which
|
||||
* is supplied by the caller. */
|
||||
int keyType; /* Type of keys to use in table:
|
||||
int keyType /* Type of keys to use in table:
|
||||
* TCL_STRING_KEYS, TCL_ONE_WORD_KEYS,
|
||||
* or an integer >= 2. */
|
||||
)
|
||||
{
|
||||
tablePtr->buckets = tablePtr->staticBuckets;
|
||||
tablePtr->staticBuckets[0] = tablePtr->staticBuckets[1] = 0;
|
||||
@@ -147,8 +148,9 @@ Tcl_InitHashTable(tablePtr, keyType)
|
||||
*/
|
||||
|
||||
void
|
||||
Tcl_DeleteHashEntry(entryPtr)
|
||||
Tcl_HashEntry *entryPtr;
|
||||
Tcl_DeleteHashEntry(
|
||||
Tcl_HashEntry *entryPtr
|
||||
)
|
||||
{
|
||||
register Tcl_HashEntry *prevPtr;
|
||||
|
||||
@@ -187,8 +189,9 @@ Tcl_DeleteHashEntry(entryPtr)
|
||||
*/
|
||||
|
||||
void
|
||||
Tcl_DeleteHashTable(tablePtr)
|
||||
register Tcl_HashTable *tablePtr; /* Table to delete. */
|
||||
Tcl_DeleteHashTable(
|
||||
register Tcl_HashTable *tablePtr /* Table to delete. */
|
||||
)
|
||||
{
|
||||
register Tcl_HashEntry *hPtr, *nextPtr;
|
||||
int i;
|
||||
@@ -246,10 +249,11 @@ Tcl_DeleteHashTable(tablePtr)
|
||||
*/
|
||||
|
||||
Tcl_HashEntry *
|
||||
Tcl_FirstHashEntry(tablePtr, searchPtr)
|
||||
Tcl_HashTable *tablePtr; /* Table to search. */
|
||||
Tcl_HashSearch *searchPtr; /* Place to store information about
|
||||
Tcl_FirstHashEntry(
|
||||
Tcl_HashTable *tablePtr, /* Table to search. */
|
||||
Tcl_HashSearch *searchPtr /* Place to store information about
|
||||
* progress through the table. */
|
||||
)
|
||||
{
|
||||
searchPtr->tablePtr = tablePtr;
|
||||
searchPtr->nextIndex = 0;
|
||||
@@ -277,11 +281,12 @@ Tcl_FirstHashEntry(tablePtr, searchPtr)
|
||||
*/
|
||||
|
||||
Tcl_HashEntry *
|
||||
Tcl_NextHashEntry(searchPtr)
|
||||
register Tcl_HashSearch *searchPtr; /* Place to store information about
|
||||
Tcl_NextHashEntry(
|
||||
register Tcl_HashSearch *searchPtr /* Place to store information about
|
||||
* progress through the table. Must
|
||||
* have been initialized by calling
|
||||
* Tcl_FirstHashEntry. */
|
||||
)
|
||||
{
|
||||
Tcl_HashEntry *hPtr;
|
||||
|
||||
@@ -318,8 +323,9 @@ Tcl_NextHashEntry(searchPtr)
|
||||
*/
|
||||
|
||||
char *
|
||||
Tcl_HashStats(tablePtr)
|
||||
Tcl_HashTable *tablePtr; /* Table for which to produce stats. */
|
||||
Tcl_HashStats(
|
||||
Tcl_HashTable *tablePtr /* Table for which to produce stats. */
|
||||
)
|
||||
{
|
||||
#define NUM_COUNTERS 10
|
||||
int count[NUM_COUNTERS], overflow, i, j;
|
||||
@@ -389,8 +395,9 @@ Tcl_HashStats(tablePtr)
|
||||
*/
|
||||
|
||||
static unsigned int
|
||||
HashString(string)
|
||||
register char *string; /* String from which to compute hash value. */
|
||||
HashString(
|
||||
register char *string /* String from which to compute hash value. */
|
||||
)
|
||||
{
|
||||
register unsigned int result;
|
||||
register int c;
|
||||
@@ -442,9 +449,10 @@ HashString(string)
|
||||
*/
|
||||
|
||||
static Tcl_HashEntry *
|
||||
StringFind(tablePtr, key)
|
||||
Tcl_HashTable *tablePtr; /* Table in which to lookup entry. */
|
||||
char *key; /* Key to use to find matching entry. */
|
||||
StringFind(
|
||||
Tcl_HashTable *tablePtr, /* Table in which to lookup entry. */
|
||||
char *key /* Key to use to find matching entry. */
|
||||
)
|
||||
{
|
||||
register Tcl_HashEntry *hPtr;
|
||||
register char *p1, *p2;
|
||||
@@ -492,12 +500,13 @@ StringFind(tablePtr, key)
|
||||
*/
|
||||
|
||||
static Tcl_HashEntry *
|
||||
StringCreate(tablePtr, key, newPtr)
|
||||
Tcl_HashTable *tablePtr; /* Table in which to lookup entry. */
|
||||
char *key; /* Key to use to find or create matching
|
||||
StringCreate(
|
||||
Tcl_HashTable *tablePtr, /* Table in which to lookup entry. */
|
||||
char *key, /* Key to use to find or create matching
|
||||
* entry. */
|
||||
int *newPtr; /* Store info here telling whether a new
|
||||
int *newPtr /* Store info here telling whether a new
|
||||
* entry was created. */
|
||||
)
|
||||
{
|
||||
register Tcl_HashEntry *hPtr;
|
||||
register char *p1, *p2;
|
||||
@@ -567,9 +576,10 @@ StringCreate(tablePtr, key, newPtr)
|
||||
*/
|
||||
|
||||
static Tcl_HashEntry *
|
||||
OneWordFind(tablePtr, key)
|
||||
Tcl_HashTable *tablePtr; /* Table in which to lookup entry. */
|
||||
register char *key; /* Key to use to find matching entry. */
|
||||
OneWordFind(
|
||||
Tcl_HashTable *tablePtr, /* Table in which to lookup entry. */
|
||||
register char *key /* Key to use to find matching entry. */
|
||||
)
|
||||
{
|
||||
register Tcl_HashEntry *hPtr;
|
||||
int index;
|
||||
@@ -611,12 +621,13 @@ OneWordFind(tablePtr, key)
|
||||
*/
|
||||
|
||||
static Tcl_HashEntry *
|
||||
OneWordCreate(tablePtr, key, newPtr)
|
||||
Tcl_HashTable *tablePtr; /* Table in which to lookup entry. */
|
||||
register char *key; /* Key to use to find or create matching
|
||||
OneWordCreate(
|
||||
Tcl_HashTable *tablePtr, /* Table in which to lookup entry. */
|
||||
register char *key, /* Key to use to find or create matching
|
||||
* entry. */
|
||||
int *newPtr; /* Store info here telling whether a new
|
||||
int *newPtr /* Store info here telling whether a new
|
||||
* entry was created. */
|
||||
)
|
||||
{
|
||||
register Tcl_HashEntry *hPtr;
|
||||
int index;
|
||||
@@ -679,9 +690,10 @@ OneWordCreate(tablePtr, key, newPtr)
|
||||
*/
|
||||
|
||||
static Tcl_HashEntry *
|
||||
ArrayFind(tablePtr, key)
|
||||
Tcl_HashTable *tablePtr; /* Table in which to lookup entry. */
|
||||
char *key; /* Key to use to find matching entry. */
|
||||
ArrayFind(
|
||||
Tcl_HashTable *tablePtr, /* Table in which to lookup entry. */
|
||||
char *key /* Key to use to find matching entry. */
|
||||
)
|
||||
{
|
||||
register Tcl_HashEntry *hPtr;
|
||||
int *arrayPtr = (int *) key;
|
||||
@@ -735,12 +747,13 @@ ArrayFind(tablePtr, key)
|
||||
*/
|
||||
|
||||
static Tcl_HashEntry *
|
||||
ArrayCreate(tablePtr, key, newPtr)
|
||||
Tcl_HashTable *tablePtr; /* Table in which to lookup entry. */
|
||||
register char *key; /* Key to use to find or create matching
|
||||
ArrayCreate(
|
||||
Tcl_HashTable *tablePtr, /* Table in which to lookup entry. */
|
||||
register char *key, /* Key to use to find or create matching
|
||||
* entry. */
|
||||
int *newPtr; /* Store info here telling whether a new
|
||||
int *newPtr /* Store info here telling whether a new
|
||||
* entry was created. */
|
||||
)
|
||||
{
|
||||
register Tcl_HashEntry *hPtr;
|
||||
int *arrayPtr = (int *) key;
|
||||
@@ -820,9 +833,10 @@ ArrayCreate(tablePtr, key, newPtr)
|
||||
|
||||
/* ARGSUSED */
|
||||
static Tcl_HashEntry *
|
||||
BogusFind(tablePtr, key)
|
||||
Tcl_HashTable *tablePtr; /* Table in which to lookup entry. */
|
||||
char *key; /* Key to use to find matching entry. */
|
||||
BogusFind(
|
||||
Tcl_HashTable *tablePtr, /* Table in which to lookup entry. */
|
||||
char *key /* Key to use to find matching entry. */
|
||||
)
|
||||
{
|
||||
panic("called Tcl_FindHashEntry on deleted table");
|
||||
return NULL;
|
||||
@@ -848,12 +862,13 @@ BogusFind(tablePtr, key)
|
||||
|
||||
/* ARGSUSED */
|
||||
static Tcl_HashEntry *
|
||||
BogusCreate(tablePtr, key, newPtr)
|
||||
Tcl_HashTable *tablePtr; /* Table in which to lookup entry. */
|
||||
char *key; /* Key to use to find or create matching
|
||||
BogusCreate(
|
||||
Tcl_HashTable *tablePtr, /* Table in which to lookup entry. */
|
||||
char *key, /* Key to use to find or create matching
|
||||
* entry. */
|
||||
int *newPtr; /* Store info here telling whether a new
|
||||
int *newPtr /* Store info here telling whether a new
|
||||
* entry was created. */
|
||||
)
|
||||
{
|
||||
panic("called Tcl_CreateHashEntry on deleted table");
|
||||
return NULL;
|
||||
@@ -880,8 +895,9 @@ BogusCreate(tablePtr, key, newPtr)
|
||||
*/
|
||||
|
||||
static void
|
||||
RebuildTable(tablePtr)
|
||||
register Tcl_HashTable *tablePtr; /* Table to enlarge. */
|
||||
RebuildTable(
|
||||
register Tcl_HashTable *tablePtr /* Table to enlarge. */
|
||||
)
|
||||
{
|
||||
int oldSize, count, index;
|
||||
Tcl_HashEntry **oldBuckets;
|
||||
|
||||
Reference in New Issue
Block a user