anchor.diff:          expectTerminals(analyzer.firstSet(parsers[#Tp]!), ['*', '']);
           expectTerminals(analyzer.firstSet(parsers[#F]!), ['(', 'i']);
         });
  +      test('ambiguous grammar', () {
  +        final parsers = createAmbiguous();
  +        final analyzer = Analyzer(parsers[#S]!);
  +        expectTerminals(analyzer.firstSet(parsers[#S]!), ['a', 'b']);
  +        expectTerminals(analyzer.firstSet(parsers[#A]!), ['a', 'b']);
  +        expectTerminals(analyzer.firstSet(parsers[#B]!), ['a']);
  +        expectTerminals(analyzer.firstSet(parsers[#a]!), ['a']);
  +        expectTerminals(analyzer.firstSet(parsers[#b]!), ['b']);
  +      });
  +      test('recursive grammar', () {
  +        final parsers = createRecursive();
  +        final analyzer = Analyzer(parsers[#S]!);
  +        expectTerminals(analyzer.firstSet(parsers[#S]!), ['p']);
  +        expectTerminals(analyzer.firstSet(parsers[#P]!), ['p']);
  +        expectTerminals(analyzer.firstSet(parsers[#p]!), ['p']);
  +      });
       });
       group('follow-set', () {
         test('plus', () {
  
positive.code:         expect(analyzer.isNullable(parsers[#Tp]!), isTrue);
          expect(analyzer.isNullable(parsers[#F]!), isFalse);
        });
      });
      group('first-set', () {
        test('plus', () {
  
negative.code:         expectTerminals(analyzer.followSet(parsers[#T]!), [')', '+', '']);
          expectTerminals(analyzer.followSet(parsers[#Tp]!), [')', '+', '']);
          expectTerminals(analyzer.followSet(parsers[#F]!), [')', '+', '*', '']);
        });
        test('ambiguous grammar', () {
          final parsers = createAmbiguous();
          final analyzer = Analyzer(parsers[#S]!);
          expectTerminals(analyzer.followSet(parsers[#S]!), ['a', '']);
          expectTerminals(analyzer.followSet(parsers[#A]!), ['a', 'b', '']);
          expectTerminals(analyzer.followSet(parsers[#B]!), ['a', 'b', '']);
          expectTerminals(analyzer.followSet(parsers[#a]!), ['a', 'b', '']);
          expectTerminals(analyzer.followSet(parsers[#b]!), ['a', 'b', '']);
        });
        test('recursive grammar', () {
          final parsers = createRecursive();
          final analyzer = Analyzer(parsers[#S]!);
          expectTerminals(analyzer.followSet(parsers[#S]!), ['+', '']);
          expectTerminals(analyzer.followSet(parsers[#P]!), ['+', '']);
          expectTerminals(analyzer.followSet(parsers[#p]!), ['+', '']);
        });
      });
    });
  