lawbreakers in Text.PrettyPrint.HughesPJ

Christian Maeder maeder at
Thu Nov 24 13:05:28 EST 2005

Conal Elliott wrote:
> Or the combinators (<>, $$, etc) might take care to build their results
> in reduced form, which seems to be the strategy that "nest" takes.

maybe that is possible, too (as now an extra call of reduceDoc for 
isEmpty is done). Fortunately isEmpty is rarely used, and if it is used 
the original input is usually thrown away.

> BTW, there's an invariant comment (about Doc, I think) that says "An
> empty document is always represented by @Empty at ."  If the combinators
> aren't going to ensure that's true, then probably the comment should be
> removed or fixed.

The comment only seems to apply to RDoc that don't have Above or Beside 
(at least on the top-level).


More information about the Libraries mailing list