Module Info.ProductionSource

include INDEXED with type 'g n = 'g production
Sourcetype 'g n = 'g production
Sourceval cardinal : 'g grammar -> 'g n Fix.Indexing.cardinal
Sourceval of_int : 'g grammar -> int -> 'g n Fix.Indexing.index

lhs p returns the left-hand side nonterminal of production p

rhs p returns the right-hand side symbols of production p

Sourceval length : 'g grammar -> 'g n Fix.Indexing.index -> int

length p returns the number of symbols on the right-hand side of production p

Sourceval kind : 'g grammar -> 'g n Fix.Indexing.index -> [ `REGULAR | `START ]

Returns `REGULAR for ordinary productions and `START for pseudo (start) productions generated for entrypoints

all g is the set of all productions in grammar g