/[bison]/bison/tests/regression.at
ViewVC logotype

Diff of /bison/tests/regression.at

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

revision 1.56 by akim, Sun Jun 30 17:33:08 2002 UTC revision 1.57 by akim, Sun Jun 30 17:33:20 2002 UTC
# Line 186  state 0 Line 186  state 0
186    
187      0 $axiom: . expr $      0 $axiom: . expr $
188    
189      'a'         shift, and go to state 1      'a'  shift, and go to state 1
190    
191      $default    reduce using rule 3 (@2)      $default  reduce using rule 3 (@2)
   
     expr        go to state 2  
     @2          go to state 3  
192    
193        expr  go to state 2
194        @2    go to state 3
195    
196    
197  state 1  state 1
198    
199      2 expr: 'a' . @1 'b'      2 expr: 'a' . @1 'b'
200    
201      $default    reduce using rule 1 (@1)      $default  reduce using rule 1 (@1)
   
     @1          go to state 4  
202    
203        @1  go to state 4
204    
205    
206  state 2  state 2
207    
208      0 $axiom: expr . $      0 $axiom: expr . $
209    
210      $           shift, and go to state 5      $  shift, and go to state 5
   
211    
212    
213  state 3  state 3
214    
215      4 expr: @2 . 'c'      4 expr: @2 . 'c'
216    
217      'c'         shift, and go to state 6      'c'  shift, and go to state 6
   
218    
219    
220  state 4  state 4
221    
222      2 expr: 'a' @1 . 'b'      2 expr: 'a' @1 . 'b'
223    
224      'b'         shift, and go to state 7      'b'  shift, and go to state 7
   
225    
226    
227  state 5  state 5
# Line 240  state 6 Line 235  state 6
235    
236      4 expr: @2 'c' .      4 expr: @2 'c' .
237    
238      $default    reduce using rule 4 (expr)      $default  reduce using rule 4 (expr)
   
239    
240    
241  state 7  state 7
242    
243      2 expr: 'a' @1 'b' .      2 expr: 'a' @1 'b' .
244    
245      $default    reduce using rule 2 (expr)      $default  reduce using rule 2 (expr)
   
   
   
246  ]])  ]])
247    
248  AT_CLEANUP  AT_CLEANUP
# Line 378  CONST_DEC: Line 369  CONST_DEC:
369  ]])  ]])
370    
371  AT_CHECK([bison -v input.y])  AT_CHECK([bison -v input.y])
372  sed -n 's/  *$//;/^$/!p' input.output >input.report  AT_CHECK([cat input.output], 0,
 AT_CHECK([cat input.report], 0,  
373  [[Grammar  [[Grammar
374    
375      0 $axiom: CONST_DEC_PART $      0 $axiom: CONST_DEC_PART $
376    
377      1 CONST_DEC_PART: CONST_DEC_LIST      1 CONST_DEC_PART: CONST_DEC_LIST
378    
379      2 CONST_DEC_LIST: CONST_DEC      2 CONST_DEC_LIST: CONST_DEC
380      3               | CONST_DEC_LIST CONST_DEC      3               | CONST_DEC_LIST CONST_DEC
381    
382      4 @1: /* empty */      4 @1: /* empty */
383    
384      5 CONST_DEC: @1 undef_id_tok '=' const_id_tok ';'      5 CONST_DEC: @1 undef_id_tok '=' const_id_tok ';'
385    
386    
387  Terminals, with rules where they appear  Terminals, with rules where they appear
388    
389  $ (0) 0  $ (0) 0
390  ';' (59) 5  ';' (59) 5
391  '=' (61) 5  '=' (61) 5
392  error (256)  error (256)
393  undef_id_tok (258) 5  undef_id_tok (258) 5
394  const_id_tok (259) 5  const_id_tok (259) 5
395    
396    
397  Nonterminals, with rules where they appear  Nonterminals, with rules where they appear
398    
399  $axiom (7)  $axiom (7)
400      on left: 0      on left: 0
401  CONST_DEC_PART (8)  CONST_DEC_PART (8)
# Line 405  CONST_DEC (10) Line 406  CONST_DEC (10)
406      on left: 5, on right: 2 3      on left: 5, on right: 2 3
407  @1 (11)  @1 (11)
408      on left: 4, on right: 5      on left: 4, on right: 5
409    
410    
411  state 0  state 0
412    
413      0 $axiom: . CONST_DEC_PART $      0 $axiom: . CONST_DEC_PART $
414      $default    reduce using rule 4 (@1)  
415      CONST_DEC_PART      go to state 1      $default  reduce using rule 4 (@1)
416      CONST_DEC_LIST      go to state 2  
417      CONST_DEC   go to state 3      CONST_DEC_PART  go to state 1
418      @1          go to state 4      CONST_DEC_LIST  go to state 2
419        CONST_DEC       go to state 3
420        @1              go to state 4
421    
422    
423  state 1  state 1
424    
425      0 $axiom: CONST_DEC_PART . $      0 $axiom: CONST_DEC_PART . $
426      $           shift, and go to state 5  
427        $  shift, and go to state 5
428    
429    
430  state 2  state 2
431    
432      1 CONST_DEC_PART: CONST_DEC_LIST .      1 CONST_DEC_PART: CONST_DEC_LIST .
433      3 CONST_DEC_LIST: CONST_DEC_LIST . CONST_DEC      3 CONST_DEC_LIST: CONST_DEC_LIST . CONST_DEC
434      undef_id_tok        reduce using rule 4 (@1)  
435      $default    reduce using rule 1 (CONST_DEC_PART)      undef_id_tok  reduce using rule 4 (@1)
436      CONST_DEC   go to state 6      $default      reduce using rule 1 (CONST_DEC_PART)
437      @1          go to state 4  
438        CONST_DEC  go to state 6
439        @1         go to state 4
440    
441    
442  state 3  state 3
443    
444      2 CONST_DEC_LIST: CONST_DEC .      2 CONST_DEC_LIST: CONST_DEC .
445      $default    reduce using rule 2 (CONST_DEC_LIST)  
446        $default  reduce using rule 2 (CONST_DEC_LIST)
447    
448    
449  state 4  state 4
450    
451      5 CONST_DEC: @1 . undef_id_tok '=' const_id_tok ';'      5 CONST_DEC: @1 . undef_id_tok '=' const_id_tok ';'
452      undef_id_tok        shift, and go to state 7  
453        undef_id_tok  shift, and go to state 7
454    
455    
456  state 5  state 5
457    
458      0 $axiom: CONST_DEC_PART $ .      0 $axiom: CONST_DEC_PART $ .
459    
460      $default    accept      $default    accept
461    
462    
463  state 6  state 6
464    
465      3 CONST_DEC_LIST: CONST_DEC_LIST CONST_DEC .      3 CONST_DEC_LIST: CONST_DEC_LIST CONST_DEC .
466      $default    reduce using rule 3 (CONST_DEC_LIST)  
467        $default  reduce using rule 3 (CONST_DEC_LIST)
468    
469    
470  state 7  state 7
471    
472      5 CONST_DEC: @1 undef_id_tok . '=' const_id_tok ';'      5 CONST_DEC: @1 undef_id_tok . '=' const_id_tok ';'
473      '='         shift, and go to state 8  
474        '='  shift, and go to state 8
475    
476    
477  state 8  state 8
478    
479      5 CONST_DEC: @1 undef_id_tok '=' . const_id_tok ';'      5 CONST_DEC: @1 undef_id_tok '=' . const_id_tok ';'
480      const_id_tok        shift, and go to state 9  
481        const_id_tok  shift, and go to state 9
482    
483    
484  state 9  state 9
485    
486      5 CONST_DEC: @1 undef_id_tok '=' const_id_tok . ';'      5 CONST_DEC: @1 undef_id_tok '=' const_id_tok . ';'
487      ';'         shift, and go to state 10  
488        ';'  shift, and go to state 10
489    
490    
491  state 10  state 10
492    
493      5 CONST_DEC: @1 undef_id_tok '=' const_id_tok ';' .      5 CONST_DEC: @1 undef_id_tok '=' const_id_tok ';' .
494      $default    reduce using rule 5 (CONST_DEC)  
495        $default  reduce using rule 5 (CONST_DEC)
496  ]])  ]])
497    
498  AT_CLEANUP  AT_CLEANUP

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