GrammarProducts-0.1.1.0: Grammar products and higher-dimensional grammars

Safe HaskellNone
LanguageHaskell2010

FormalLanguage.GrammarProduct.Op.Add

Synopsis

Documentation

newtype Add a Source

Add two grammars. Implemented as the union of production rules without any renaming.

Constructors

Add 

Fields

runAdd :: a
 

Instances

Monoid (Add Grammar) 
Semigroup (Add Grammar)

Note that the semigroup on Add will create a new rule S_gh -> S_g | S_h in case two start symbols with different rhs exist (If S_g, S_h are the same, there is no problem).