Fork me on GitHub

hello, I'm trying to use rewrite-clj to analyse some code, I start from clj-kondo analysis info which contains row and col of what I need, how can I navigate to something on rewrite-clj based on row/col?


@wilkerlucio rewrite-clj provides find-last-by-pos which lets you seek to a node if you know its position. There are some caveats to using that function. It only works if you have a :track-position? zipper. And it can be slow, especially if you’re working in large files. See this for some alternative code that works around both of those problems. Feel free to :thumbsup: that issue if you’d like to see it worked on ;).


thanks! checking it out