public ParserProduction(ParserAutomata automata, Grammar <TToken> .ParserRule parserRule, Grammar <TToken> .ParserProduction grammarParserProduction, List <ParserProduction> productions)
                    : base(grammarParserProduction.Entries.Select(automata.CreateParserEntry))
                {
                    Name     = grammarParserProduction.Name ?? automata.GenerateProductionName();
                    IsInline = parserRule.IsInline;
                    GrammarParserProduction = grammarParserProduction;
                    ProductionIndex         = productions.Count;

                    productions.Add(this);

                    Flatten();

                    if (IsInline)
                    {
                        return;
                    }

                    Binder = grammarParserProduction.Binding switch
                    {
                        Grammar <TToken> .ConstructorParserProductionBinding _ => new CtorParserProductionBinder(this),
                        Grammar <TToken> .SyntaxFactoryParserProductionBinding _ => new SyntaxFactoryProductionBinder(this),
                        null => null,
                        _ => throw new InvalidOperationException("Unknown binder")
                    };
                }