X-Git-Url: http://git.chise.org/gitweb/?a=blobdiff_plain;f=lib-src%2Fsorted-doc.c;h=d66ce778971c5f0add4bd600b01212f547a98d73;hb=5b7f2392a52c598bbef83d0d018289b73833567d;hp=0b77c45ee4400858329eecd8edb80e5fd0081585;hpb=716cfba952c1dc0d2cf5c968971f3780ba728a89;p=chise%2Fxemacs-chise.git.1 diff --git a/lib-src/sorted-doc.c b/lib-src/sorted-doc.c index 0b77c45..d66ce77 100644 --- a/lib-src/sorted-doc.c +++ b/lib-src/sorted-doc.c @@ -14,9 +14,6 @@ #include /* for qsort() and malloc() */ #include static void *xmalloc (size_t); -#ifndef CONST -# define CONST const -#endif #define NUL '\0' #define MARKER '\037' @@ -96,7 +93,7 @@ enum state WAITING, BEG_NAME, NAME_GET, BEG_DESC, DESC_GET }; -CONST char *states[] = +const char *states[] = { "WAITING", "BEG_NAME", "NAME_GET", "BEG_DESC", "DESC_GET" }; @@ -201,12 +198,7 @@ main (int argc, char *argv[]) /* sort the array by name; within each name, by type */ qsort ((char*)array, cnt, sizeof (DOCSTR*), - /* was cast to (int (*)(CONST void *, CONST void *)) - but that loses on HP because CONST_IS_LOSING. */ - /* This one loses too: (int (*)()) */ - /* Ok, so let's try const instead of CONST. Fuck me!!! */ - (int (*)(const void *, const void *)) - cmpdoc); + (int (*)(const void *, const void *)) cmpdoc); /* write the output header */