Repository navigation
Follow hlint suggestion: move brackets to avoid $ - #9112
Conversation
ffaf1
left a comment
There was a problem hiding this comment.
Apart from the do block, reasonable.
| ( when (flag haddockForeignLibs) $ do | ||
| withTempDirectoryEx verbosity tmpFileOpts (buildDir lbi') "tmp" $ | ||
| \tmp -> do | ||
| smsg | ||
| flibArgs <- | ||
| fromForeignLib | ||
| verbosity | ||
| tmp | ||
| lbi' | ||
| clbi | ||
| htmlTemplate | ||
| version | ||
| flib | ||
| let libArgs' = commonArgs `mappend` flibArgs | ||
| runHaddock verbosity tmpFileOpts comp platform haddockProg True libArgs' | ||
| ) | ||
| when | ||
| (flag haddockForeignLibs) | ||
| ( do | ||
| withTempDirectoryEx verbosity tmpFileOpts (buildDir lbi') "tmp" $ | ||
| \tmp -> do | ||
| smsg | ||
| flibArgs <- |
There was a problem hiding this comment.
I get that. I looked at it a while and concluded the difficulty in reading the code block was there beforehand.
There was a problem hiding this comment.
I agree, perhaps you should consider trying to make this part it more readable.
There was a problem hiding this comment.
Personally, I'm a heavy user of $ and I also don't like these new parens. But I can live with them no problem.
| <<>> parens pkgkind | ||
| $+$ ( nest 4 $ | ||
| vcat | ||
| $+$ nest 4 (vcat |
There was a problem hiding this comment.
Closing bracket 30+ lines later, odd but followable.
There was a problem hiding this comment.
I could have used indentation but didn't want to unindent so many lines, aiming for a small change.
There was a problem hiding this comment.
The closing ) was also far before right?
There was a problem hiding this comment.
Yes, +1 to Andrea's comment: it was far away in the initial version too.
| [ comp2str c | ||
| J..= ( J.object $ | ||
| J..= J.object | ||
| ( |
There was a problem hiding this comment.
Again a weird Allman-style bracket, but still readable in an editor.
There was a problem hiding this comment.
Not sure who's Allman (Wikipedia says, his indentation style does 8 spaces for a tab, and that's about it) but an extra line that the new version takes is unfortunate, indeed. Again, hardly critical.
andreabedini
left a comment
There was a problem hiding this comment.
I am good with this 👍
ulysses4ever
left a comment
There was a problem hiding this comment.
Don't see any controversy here. Thanks!
See #9110.