
Hi, Am Montag, den 01.07.2013, 07:59 -0400 schrieb Richard Cobbe:
How does the indentation tool know if (a b c) is supposed to be the next item in the do block, or merely a continuation of the previous application of f?
I would still expect the developer to write correctly intended Haskell, so the the tool would have to employ a Haskell parser to get an AST (with extra information on where comments were – probably the trickiest part) and then pretty-prints it. If it were not for comments, using haskell-src-exts would already provide a first approximation to the problem, as shown in this script: https://github.com/djv/small/blob/master/tidy.hs Greetings, Joachim -- Joachim “nomeata” Breitner mail@joachim-breitner.de • http://www.joachim-breitner.de/ Jabber: nomeata@joachim-breitner.de • GPG-Key: 0x4743206C Debian Developer: nomeata@debian.org