[BACK]Return to cond.c CVS log [TXT][DIR] Up to [local] / src / usr.bin / make

Diff for /src/usr.bin/make/cond.c between version 1.47 and 1.48

version 1.47, 2012/10/18 17:54:43 version 1.48, 2012/11/24 11:04:55
Line 198 
Line 198 
         const char *cp;          const char *cp;
   
         cp = *linePtr;          cp = *linePtr;
           /* Set things up to return faster in case of problem */
           arg->s = cp;
           arg->e = cp;
           arg->tofree = false;
   
           /* make and defined are not really keywords, so if CondGetArg doesn't
            * work...
            */
         if (parens) {          if (parens) {
                 while (*cp != '(' && *cp != '\0')                  while (isspace(*cp))
                         cp++;                          cp++;
                 if (*cp == '(')                  if (*cp == '(')
                         cp++;                          cp++;
                   else
                           return false;
         }          }
   
         if (*cp == '\0') {          if (*cp == '\0')
                 /* No arguments whatsoever. Because 'make' and 'defined' aren't  
                  * really "reserved words", we don't print a message. I think  
                  * this is better than hitting the user with a warning message  
                  * every time s/he uses the word 'make' or 'defined' at the  
                  * beginning of a symbol...  */  
                 arg->s = cp;  
                 arg->e = cp;  
                 arg->tofree = false;  
                 return false;                  return false;
         }  
   
         while (*cp == ' ' || *cp == '\t')          while (isspace(*cp))
                 cp++;                  cp++;
   
   
         cp = VarName_Get(cp, arg, NULL, true, find_cond);          cp = VarName_Get(cp, arg, NULL, true, find_cond);
   
         while (*cp == ' ' || *cp == '\t')          while (isspace(*cp))
                 cp++;                  cp++;
         if (parens && *cp != ')') {          if (parens) {
                 Parse_Error(PARSE_WARNING,                  if (*cp == ')')
                     "Missing closing parenthesis for %s()", func);                          cp++;
             return false;                  else {
         } else if (parens)                          Parse_Error(PARSE_WARNING,
                 /* Advance pointer past close parenthesis.  */                              "Missing closing parenthesis for %s()", func);
                 cp++;                          return false;
                   }
           }
   
         *linePtr = cp;          *linePtr = cp;
         return true;          return true;
Line 747 
Line 749 
                 return t;                  return t;
         }          }
   
         while (*condExpr == ' ' || *condExpr == '\t')          while (isspace(*condExpr))
                 condExpr++;                  condExpr++;
         switch (*condExpr) {          switch (*condExpr) {
         case '(':          case '(':

Legend:
Removed from v.1.47  
changed lines
  Added in v.1.48