[project @ 2005-07-12 17:07:56 by panne]
authorpanne <unknown>
Tue, 12 Jul 2005 17:07:56 +0000 (17:07 +0000)
committerpanne <unknown>
Tue, 12 Jul 2005 17:07:56 +0000 (17:07 +0000)
Add casts to silence warnings when using Solaris' simple-minded isupper() macro.

ghc/utils/hp2ps/AuxFile.c
ghc/utils/hp2ps/HpFile.c

index 06cfd6c..9998d3f 100644 (file)
@@ -127,7 +127,7 @@ FILE* auxfp;
         return;
     } else if (IsIdChar(ch)) {          /* ch can't be a digit here */
         GetIdent(auxfp);
-       if (!isupper(theident[0])) {
+       if (!isupper((int)theident[0])) {
             thetok = IDENTIFIER_TOK;
         } else if (strcmp(theident, "X_RANGE") == 0) {
             thetok = X_RANGE_TOK;
index 2fe5e06..9db9497 100644 (file)
@@ -304,7 +304,7 @@ GetHpTok(infp)
     } else if (IsIdChar(ch)) {
        ASSERT(! (isdigit(ch)));        /* ch can't be a digit here */
        GetIdent(infp);
-       if (!isupper(theident[0])) {
+       if (!isupper((int)theident[0])) {
            thetok = IDENTIFIER_TOK;
        } else if (strcmp(theident, "BEGIN_SAMPLE") == 0) {
             thetok = BEGIN_SAMPLE_TOK;