Skip to content

Commit

Permalink
vscode issue 616
Browse files Browse the repository at this point in the history
  • Loading branch information
ZacLN committed Dec 24, 2018
1 parent cd09bbe commit 248bc75
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions src/passes.jl
Original file line number Diff line number Diff line change
Expand Up @@ -43,9 +43,10 @@ function tuple_pass(x, state)
offset = state.offset
n = length(x)
for (i, a) in enumerate(x)
if a isa CSTParser.PUNCTUATION && a.kind == Tokens.COMMA && i !=n && !(x.args[i+1] isa CSTParser.PUNCTUATION)
i == n && continue
if a isa CSTParser.PUNCTUATION && a.kind == Tokens.COMMA && !(x.args[i+1] isa CSTParser.PUNCTUATION)
ensure_single_space_after(a, state, offset)
elseif i != n
elseif !(x.args[i + 1] isa CSTParser.EXPR{CSTParser.Parameters})
ensure_no_space_after(a, state, offset)
end
offset += a.fullspan
Expand Down

0 comments on commit 248bc75

Please sign in to comment.