diff options
| author | Nick Barnes | 2001-10-31 14:40:56 +0000 |
|---|---|---|
| committer | Nick Barnes | 2001-10-31 14:40:56 +0000 |
| commit | 7acfca905d76140f4cc0b09c9a12de237de364cd (patch) | |
| tree | 3ed8babfa3a73d30f29e08ca5d5adcda4ca4e826 /mps/code/table.h | |
| parent | b7ce4893f9902d57cd67ac9a92fa6c3d5a8fc833 (diff) | |
| download | emacs-7acfca905d76140f4cc0b09c9a12de237de364cd.tar.gz emacs-7acfca905d76140f4cc0b09c9a12de237de364cd.zip | |
Branch imports for masters.
Copied from Perforce
Change: 23678
ServerID: perforce.ravenbrook.com
Diffstat (limited to 'mps/code/table.h')
| -rw-r--r-- | mps/code/table.h | 26 |
1 files changed, 26 insertions, 0 deletions
diff --git a/mps/code/table.h b/mps/code/table.h new file mode 100644 index 00000000000..46864a54b1b --- /dev/null +++ b/mps/code/table.h | |||
| @@ -0,0 +1,26 @@ | |||
| 1 | /* impl.h.table: Interface for a dictionary | ||
| 2 | * Copyright (C) 1997, 1999 Harlequin Group plc. All rights reserved. | ||
| 3 | * | ||
| 4 | * $HopeName: MMsrc!table.h(trunk.1) $ | ||
| 5 | */ | ||
| 6 | |||
| 7 | #ifndef table_h | ||
| 8 | #define table_h | ||
| 9 | |||
| 10 | #include "mpmtypes.h" | ||
| 11 | #include <stddef.h> | ||
| 12 | |||
| 13 | |||
| 14 | typedef struct TableStruct *Table; | ||
| 15 | |||
| 16 | extern Res TableCreate(Table *tableReturn, size_t length); | ||
| 17 | extern void TableDestroy(Table table); | ||
| 18 | extern Res TableDefine(Table table, Word key, void *value); | ||
| 19 | extern Res TableRedefine(Table table, Word key, void *value); | ||
| 20 | extern Bool TableLookup(void **valueReturn, Table table, Word key); | ||
| 21 | extern Res TableRemove(Table table, Word key); | ||
| 22 | extern size_t TableCount(Table table); | ||
| 23 | extern void TableMap(Table table, void(*fun)(Word key, void *value)); | ||
| 24 | |||
| 25 | |||
| 26 | #endif /* table_h */ | ||