JuliaEditorSupport / julia-vim

Vim support for Julia.
http://julialang.org/
Other
755 stars 94 forks source link

Indentation support for function chaining #264

Open digital-carver opened 3 years ago

digital-carver commented 3 years ago

Currently, function chaining gets no indent:

myvariable = readline(infile) |>
collect |>
a -> reshape(a, (9, 9)) |>
permutedims

Something like what's below would be preferable, as with function arguments and the other examples mentioned in the docs.

myvariable = readline(infile) |>
              collect |>
              a -> reshape(a, (9, 9)) |>
              permutedims
TerseTears commented 3 years ago

I think the issue is with every infix operator, whereby breaking the line after the operator, simply doesn't indent the line that follows. Not sure if it's the proper style, but it is what I'm used to as well.