mirror of
https://github.com/jeremysrand/abCalc.git
synced 2024-12-28 12:32:55 +00:00
Make operation lookups case insensitive on both platforms
This commit is contained in:
parent
e77709f015
commit
88102cafea
4
Makefile
4
Makefile
@ -4,6 +4,8 @@ all: $(NAME)
|
|||||||
|
|
||||||
.INCLUDE: "Make.engine"
|
.INCLUDE: "Make.engine"
|
||||||
|
|
||||||
|
CFLAGS=-D ABCALC_GSOS
|
||||||
|
|
||||||
$(NAME): fixtype $(OBJS)
|
$(NAME): fixtype $(OBJS)
|
||||||
occ -o $(NAME) $(OBJS)
|
occ -o $(NAME) $(OBJS)
|
||||||
|
|
||||||
@ -19,4 +21,4 @@ fixtype:
|
|||||||
chtyp -l CC ops/*.c ops/*.h
|
chtyp -l CC ops/*.c ops/*.h
|
||||||
|
|
||||||
%.o: %.c
|
%.o: %.c
|
||||||
occ -c $<
|
occ $(CFLAGS) -c $<
|
||||||
|
BIN
ops/.abCOp.c.swp
Normal file
BIN
ops/.abCOp.c.swp
Normal file
Binary file not shown.
@ -92,7 +92,11 @@ abCalcOp *abCalcOpLookup(char *name)
|
|||||||
int i;
|
int i;
|
||||||
|
|
||||||
for (i = 0; i < gNumOps; i++) {
|
for (i = 0; i < gNumOps; i++) {
|
||||||
if (strcmp(gOps[i].name, name) == 0) {
|
#ifdef ABCALC_GSOS
|
||||||
|
if (stricmp(gOps[i].name, name) == 0) {
|
||||||
|
#else
|
||||||
|
if (strcasecmp(gOps[i].name, name) == 0) {
|
||||||
|
#endif
|
||||||
return &gOps[i];
|
return &gOps[i];
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user