Improve depth-cutoff for printing HsSyn in error messages
authorsimonpj@microsoft.com <unknown>
Sun, 22 Apr 2007 21:10:49 +0000 (21:10 +0000)
committersimonpj@microsoft.com <unknown>
Sun, 22 Apr 2007 21:10:49 +0000 (21:10 +0000)
commitd38a30cb5e7a946f7a5e02fb6e601d2d37ea4374
tree6fcb7873281bd7c86b3fc22558f0f0c2d26a219c
parent618380a7fa2ca7b75b2b6a5bfa7eac4a86941510
Improve depth-cutoff for printing HsSyn in error messages

MERGE TO STABLE

The "user style" in Outputable allows us to elide large expressions
when printing HsSyn, printing "..." instead.  This is done by calling
Outputable.pprDeeper.

But there was no mechanism for trimming very long lists, which
occur when using do-notation or explicit lists.  This patch fixes
the problem, by adding Outputable.pprDeeperList.

I also made some of the pretty-printing in HsExpr rather more
vigorous about increasing the depth; in particular, pprParendExpr.
This should make debug prints shorter.
compiler/hsSyn/HsExpr.lhs
compiler/utils/Outputable.lhs