/[bison]/bison/src/conflicts.c
ViewVC logotype

Diff of /bison/src/conflicts.c

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 1.56 by akim, Mon Dec 17 17:32:58 2001 UTC revision 1.57 by akim, Sat Dec 22 14:42:35 2001 UTC
# Line 413  void Line 413  void
413  print_reductions (FILE *out, int state)  print_reductions (FILE *out, int state)
414  {  {
415    int i;    int i;
   int j;  
416    int m = state_table[state]->lookaheadsp;    int m = state_table[state]->lookaheadsp;
417    int n = state_table[state + 1]->lookaheadsp;    int n = state_table[state + 1]->lookaheadsp;
418    shifts *shiftp = state_table[state]->shifts;    shifts *shiftp = state_table[state]->shifts;
# Line 457  print_reductions (FILE *out, int state) Line 456  print_reductions (FILE *out, int state)
456      }      }
457    else if (n - m >= 1)    else if (n - m >= 1)
458      {      {
       int k;  
   
459        int cmax = 0;        int cmax = 0;
460        int default_LA = -1;        int default_LA = -1;
461        int default_rule = 0;        int default_rule = 0;
# Line 467  print_reductions (FILE *out, int state) Line 464  print_reductions (FILE *out, int state)
464          for (i = m; i < n; i++)          for (i = m; i < n; i++)
465            {            {
466              int count = 0;              int count = 0;
467                int j, k;
468    
469              for (k = 0; k < tokensetsize; ++k)              for (k = 0; k < tokensetsize; ++k)
470                lookaheadset[k] = LA (i)[k] & ~shiftset[k];                lookaheadset[k] = LA (i)[k] & ~shiftset[k];
# Line 495  print_reductions (FILE *out, int state) Line 493  print_reductions (FILE *out, int state)
493    
494        for (i = 0; i < ntokens; i++)        for (i = 0; i < ntokens; i++)
495          {          {
496              int j;
497            int defaulted = 0;            int defaulted = 0;
498            int count = BITISSET (shiftset, i);            int count = BITISSET (shiftset, i);
499    
500            for (j = m; j < n; j++)            for (j = m; j < n; j++)
501              {              {
502                if (BITISSET (LA (m), j))                if (BITISSET (LA (j), i))
503                  {                  {
504                    if (count == 0)                    if (count == 0)
505                      {                      {

Legend:
Removed from v.1.56  
changed lines
  Added in v.1.57

savannah-hackers-public@gnu.org
ViewVC Help
Powered by ViewVC 1.1.26