[Haskell-cafe] Re: Examples of Mutually Recursive Types

Larry Evans cppljevans at suddenlink.net
Sun Oct 26 19:43:55 EDT 2008


On 10/26/08 17:06, Hugo Pacheco wrote:
> Probably I overdid the real part.
> I was thinking of examples such as ASTs (such as the Haskell one), trees 
> and imagining more fancy things, maybe L-systems and fractal processing.
> I will have a look at the Haskell sources and the previous papers 
> from Tim Sheard.
One example is a language grammar.  Each non-terminal in the grammar
can reference any other non-terminal in the grammar.  Thus, if
the non-terminals are considered types, then each non-terminal in a
grammar is mutually recursive with respect to other non-terminals in
that grammar.



More information about the Haskell-Cafe mailing list