You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
now if conditions code structure:
if a &
b &
c {
}
i dont think this is clearly if a/b/c is long expression.
how about organize if conditions like this:
if a
& b
& c {
}
i think this will make relations between a,b,c clearly.
The text was updated successfully, but these errors were encountered:
this is prevented by the automatic semicolon insertion rules. From the spec:
The formal grammar uses semicolons ";" as terminators in a number of productions [...]
When the input is broken into tokens, a semicolon is automatically inserted into the token stream immediately after a line's final token if that token is
an identifier
if a would be turned into if a; so it's mandatory that the line ends with the logical operator.
Also the gofmt format has been quite stable since the Go1 release, and at this point it's unlikely to change much.
now if conditions code structure:
if a &
b &
c {
}
i dont think this is clearly if a/b/c is long expression.
how about organize if conditions like this:
if a
& b
& c {
}
i think this will make relations between a,b,c clearly.
The text was updated successfully, but these errors were encountered: