>> + (sexp-default >> + ;; For `C-M-f' in "#|(a)" >> + ("(" . ,(lambda (node) >> + (and (eq (char-before (point)) ?\#) >> + (equal (treesit-node-type (treesit-node-parent node)) >> + "anon_fn_lit"))))) > Thanks Juri. I tried your patch and for some reason it doesn't solve the > issue neither with 'raise-sexp' nor with 'C-M-f' navigation. The point is > moved from: > > #|(-> (.-value (.-target %))) > > to > > #(-> (.-value (.-target %))|) I tested that this patch fixes 'C-M-f' navigation where point moves to #(-> (.-value (.-target %)))| > and 'raise-sexp' called from: > > #(-> |(.-value (.-target %))) > > produces: > > #(.-value (.-target %))) Indeed, it didn't fix this case. For down/up-list it needs to use 'sexp' thing instead of 'list' thing. Probably the simplest setting would be to redefine down-list-function/up-list-function. Ok, here is a complete tested patch that fixes all your test cases: