Qualifiers were observed too often. Instead tokens are treated as
authorAdam Dickmeiss <adam@indexdata.dk>
Thu, 20 Jul 1995 08:14:34 +0000 (08:14 +0000)
committerAdam Dickmeiss <adam@indexdata.dk>
Thu, 20 Jul 1995 08:14:34 +0000 (08:14 +0000)
qualifiers only when separated by comma.

ccl/cclfind.c

index ab16f42..fe77fe4 100644 (file)
  * Europagate, 1995
  *
  * $Log: cclfind.c,v $
- * Revision 1.14  1995/05/16 09:39:26  adam
+ * Revision 1.15  1995/07/20 08:14:34  adam
+ * Qualifiers were observed too often. Instead tokens are treated as
+ * qualifiers only when separated by comma.
+ *
+ * Revision 1.14  1995/05/16  09:39:26  adam
  * LICENSE.
  *
  * Revision 1.13  1995/04/17  09:31:42  adam
@@ -706,10 +710,15 @@ static struct ccl_rpn_node *search_elements (struct ccl_rpn_attr **qa)
     }
     lookahead = look_token;
 
-    while (lookahead->kind==CCL_TOK_TERM || lookahead->kind==CCL_TOK_COMMA)
-       lookahead = lookahead->next;
-    if (lookahead->kind == CCL_TOK_REL || lookahead->kind == CCL_TOK_EQ)
-       return qualifiers (lookahead, qa);
+    while (lookahead->kind==CCL_TOK_TERM)
+    {
+        lookahead = lookahead->next;
+        if (lookahead->kind == CCL_TOK_REL || lookahead->kind == CCL_TOK_EQ)
+           return qualifiers (lookahead, qa);
+        if (lookahead->kind != CCL_TOK_COMMA)
+            break;
+        lookahead = lookahead->next;
+    }
     return search_terms (qa);
 }