-
Notifications
You must be signed in to change notification settings - Fork 3.4k
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
Formatting: add white space after comma #4491
Conversation
@@ -735,7 +735,7 @@ defmodule KernelTest do | |||
|
|||
test "multi-call" do | |||
assert capture_io(fn -> | |||
Code.eval_string("use UseMacro.{SampleA, SampleB,}", [], __ENV__) | |||
Code.eval_string("use UseMacro.{SampleA, SampleB, }", [], __ENV__) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
✂️
Thank you @eksperimental. @ericmj has already left some comments. @lexmag, I will leave this one up to you. :) ❤️ |
I'm not understanding why we're putting spaces around |
@whatyouhide: in short because Creating a PR that puts a white-space around the plus the use |
So maybe adding spaces around all |
I can revert those. no problem |
We agreed on having spaces around |
end | ||
|
||
test "evaluates with defined variable" do | ||
assert_eval "foo 1", "foo <% bar = 1 %><%= bar %>" | ||
end | ||
|
||
test "evaluates with require code" do | ||
assert_eval "foo 1,2,3", "foo <% require Enum, as: E %><%= E.join [1, 2, 3], \",\" %>" | ||
assert_eval "foo 1, 2, 3", "foo <% require Enum, as: E %><%= E.join [1, 2, 3], \", \" %>" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Let's keep previous formatting here as it is not a code but data.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
fixed
@eksperimental I've just added very last comment, LGTM. |
@eksperimental right, let's preserve |
@@ -25,22 +25,22 @@ defmodule FileTest do | |||
# | |||
# Renaming files | |||
# :ok -> rename file to existing file default behaviour | |||
# {:error,:eisdir} -> rename file to existing empty dir | |||
# {:error,:eisdir} -> rename file to existing non empty dir | |||
# {:error, :eisdir} -> rename file to existing empty dir |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
These arrows have gotten broken indentation.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
fixed under "Renaming files" and "Renaming dirs" sections
Standardizes the use of comma leaving a white space after it whenever applicable. Note: It does not enforce this in quantifiers in regular expressions such as in: `x{1,3}`
💛 |
Standardizes the use of comma leaving a white space after it whenever applicable.
Note #1: In the changed lines it also adds a white space surrounding the
|
when there is more than one element to the left.Example: before was
[a,b|tail]
now it is:[a, b | tail]
..Note #2: It does not enforce this in quantifiers in regular expressions such as in:
x{1,3}