[Haskell-cafe] Indentation Creep

Bulat Ziganshin bulat.ziganshin at gmail.com
Sat Jul 14 14:55:06 EDT 2007

Hello Thomas,

Saturday, July 14, 2007, 12:59:16 AM, you wrote:

>                             case re of
>                                 False -> writeTVar m Nothing
>                                 True  -> writeTVar p Empty

> All that case analysis causes indentation to creep, and lots of
> vertical space "feels" wasted. Is that just a fact of life, or is
> there Haskellmagic that I still need to learn?

this code actually looks as core Haskell, to which all Haskell code
desugared by compiler :)  i will not add too much to answers al;ready
given, but when your function look too long - split it into several
ones. it's one more way to decrease indenting. you may use local
functions via 'where' or 'let' if you don't want to make them global

Best regards,
 Bulat                            mailto:Bulat.Ziganshin at gmail.com

More information about the Haskell-Cafe mailing list