-
Notifications
You must be signed in to change notification settings - Fork 187
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
brace_linter()
could allow skipping braces in function factories
#1807
Comments
WDYT about making it the same option as allowing e.g.
? |
Wouldn't that disable that particular lint completely? |
No, there's still function(x)
AWrapper(y, x)
function(x)
AWrapper(
y,
x
) |
Ah okay. Any ideas for an option name? |
But omitting braces here reduces readability, since the reader now needs to mentally add those braces back in. function() function(x) {
x
} Why should we make an exception for such an omission? That is, why is it so important here to leave out braces? |
Because you need two additional lines and an additional level of indent. |
Agree it can be useful, and warrants an argument, but also that it should not be the default choice. |
Okay, thanks for the explaining. Makes sense. As for the parameter name, how about |
is |
|
Created on 2022-12-07 with reprex v2.0.2
This could optionally be allowed in addition to
The text was updated successfully, but these errors were encountered: