Updated WIN32 code specific sections. Changed header.
[idzebra-moved-to-github.git] / dfa / dfa.c
index e1e1c45..73730c8 100644 (file)
--- a/dfa/dfa.c
+++ b/dfa/dfa.c
@@ -1,10 +1,19 @@
 /*
- * Copyright (C) 1994-1998, Index Data I/S 
+ * Copyright (C) 1994-1999, Index Data
  * All rights reserved.
  * Sebastian Hammer, Adam Dickmeiss
  *
  * $Log: dfa.c,v $
- * Revision 1.22  1998-06-24 12:16:10  adam
+ * Revision 1.25  1999-02-02 14:50:05  adam
+ * Updated WIN32 code specific sections. Changed header.
+ *
+ * Revision 1.24  1998/10/28 10:48:55  adam
+ * Added type cast to prevent warning.
+ *
+ * Revision 1.23  1998/09/02 14:15:28  adam
+ * Zebra uses GNU Configure.
+ *
+ * Revision 1.22  1998/06/24 12:16:10  adam
  * Support for relations on text operands. Open range support in
  * DFA module (i.e. [-j], [g-]).
  *
@@ -537,7 +546,7 @@ static int lex_sub(struct DFA_parse *parse_info)
         {
             const int *cc;
             for (cc = parse_info->charMap; *cc; cc += 2)
-                if (*cc == parse_info->look_ch)
+                if (*cc == (int) (parse_info->look_ch))
                 {
                     if (!cc[1])
                         --parse_info->expr_ptr;
@@ -773,6 +782,7 @@ static void dfa_trav (struct DFA_parse *parse_info, struct Tnode *n)
         n->lastpos = mk_Set (poset);
         n->lastpos = add_Set (poset, n->lastpos, n->pos);
         if (debug_dfa_trav)
+       {
             if (n->u.ch[0] < 0)
                 printf ("#%d (n#%d)", -n->u.ch[0], -n->u.ch[1]);
             else if (n->u.ch[1] > n->u.ch[0])
@@ -786,6 +796,7 @@ static void dfa_trav (struct DFA_parse *parse_info, struct Tnode *n)
             }
             else
                 out_char (n->u.ch[0]);
+       }
     }
     if (debug_dfa_trav)
     {
@@ -856,10 +867,12 @@ static void mk_dfa_tran (struct DFA_parse *parse_info, struct DFA_states *dfas)
             for (pos_i = pos; (i = *pos_i) != -1; ++pos_i)
                 if (posar[i]->u.ch[1] >= char_1 
                     && (c=posar[i]->u.ch[0]) < char_0)
+               {
                     if (c < char_1)
                         char_0 = char_1;
                     else
                         char_0 = c;
+               }
 
             if (char_0 > max_char)
                 break;