Alignment of by clauses in reasoning syntax
#1628
Replies: 2 comments 4 replies
-
|
I support your proposal. In addition, there is a question of wheter the outer indentation should be there too, i.e., equational-reasoning
term-1
= term-2
by
equation-1
= term-3
by
equation-2I think this can be justified by the same reasons. |
Beta Was this translation helpful? Give feedback.
-
|
I'll admit this is a case where I find indentation to help my ability to follow what's going on. I'd cheerfully love to find ways to deindent It feels significantly more natural to me to indent the body of |
Beta Was this translation helpful? Give feedback.
Uh oh!
There was an error while loading. Please reload this page.
-
The code style guidelines describe the following formatting for
byclausesHowever it's becoming more frequent to use
There are reasons to prefer either, but I think we should converge on one style and follow it. I'm opening a discussion to see if anyone has a strong reason to prefer the second style. I see it looks more consistent with function application, but in this context we treat
byas a keyword, and the first style is consistent with how we treatwherew.r.t. reducing right drift. Unless a strong reason is presented, I support enforcing the first style in PR reviews going forward (and writing a lint; rejecting files matching^( +)by\n\1 +looks sound enough).Beta Was this translation helpful? Give feedback.
All reactions