home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Usenet 1994 January
/
usenetsourcesnewsgroupsinfomagicjanuary1994.iso
/
sources
/
misc
/
volume6
/
lookup.c++
/
lookup2.c
< prev
next >
Encoding:
Amiga
Atari
Commodore
DOS
FM Towns/JPY
Macintosh
Macintosh JP
Macintosh to JP
NeXTSTEP
RISC OS/Acorn
Shift JIS
UTF-8
Wrap
C/C++ Source or Header
|
1989-03-04
|
263 b
|
16 lines
#include <stream.h>
#include <string.h>
#include "lookup.h"
proc lookup::operator[](const char *str)
{
entry *t=table;
for(; t-table < max; t++)
if(!strcmp(t->name, str))
break;
if(t-table<max) return t->f;
else return dflt;
}