guns/vim-clojure-static

Weird behaviour of -> and ->> indention inside defn

Gonzih opened this issue · 2 comments

Hi, I love current indention of -> and ->> but I found something strange when I'm trying to use -> or ->> inside defn

(defn a [b]
  (-> k
            z
            d
            c))

(defn z [k]
  (->> a
            b
            c))

(defn z []
  (->> a
           (-> a
         b
         c
         z)))

But it's ok when argument list is on separate line:

(defn a
  [b]
  (-> a
      b
      c))

Also nested -> or ->> usage can be indented in the wrong way:

(-> a
    b
    (->> map
      (fun)
      k)
    i)

vim version is 7.3.875

Btw thanks for keeping vim and clojure together! :)

guns commented

Hello @Gonzih!

This was caused by a regression in Vim in 7.3.871, which has been addressed in 7.3.877. Could you please update and see if this fixes things for you?

See issue 21 for more information.

Thank you.

guns commented

@Gonzih

I'm going to close this issue since I believe it is a duplicate of issue #21. If I am in error, please feel free to reopen.

Thank you