From c656bf3946268d9d0b87174af6e26d32075dfe01 Mon Sep 17 00:00:00 2001 From: Florian Diebold Date: Thu, 14 Mar 2019 22:08:37 +0100 Subject: Fix ra-emacs-lsp for newest lsp-mode with native json support --- editors/emacs/ra-emacs-lsp.el | 9 ++++----- 1 file changed, 4 insertions(+), 5 deletions(-) (limited to 'editors/emacs') diff --git a/editors/emacs/ra-emacs-lsp.el b/editors/emacs/ra-emacs-lsp.el index 780182f8a..955703edb 100644 --- a/editors/emacs/ra-emacs-lsp.el +++ b/editors/emacs/ra-emacs-lsp.el @@ -58,17 +58,16 @@ (defun rust-analyzer--apply-source-change (data) ;; TODO fileSystemEdits - (--each (-> data (ht-get "workspaceEdit") (ht-get "documentChanges")) + (seq-doseq (it (-> data (ht-get "workspaceEdit") (ht-get "documentChanges"))) (rust-analyzer--apply-text-document-edit it)) (-when-let (cursor-position (ht-get data "cursorPosition")) (let ((filename (rust-analyzer--uri-filename (ht-get cursor-position "textDocument"))) (position (ht-get cursor-position "position"))) (find-file filename) - (rust-analyzer--goto-lsp-loc position) - ))) + (rust-analyzer--goto-lsp-loc position)))) (defun rust-analyzer--apply-source-change-command (p) - (let ((data (-> p (ht-get "arguments") (car)))) + (let ((data (-> p (ht-get "arguments") (seq-first)))) (rust-analyzer--apply-source-change data))) (lsp-register-client @@ -126,7 +125,7 @@ "rust-analyzer/extendSelection" (rust-analyzer--extend-selection-params))) (ht-get "selections") - (car))) + (seq-first))) (defun rust-analyzer--add-er-expansion () (make-variable-buffer-local 'er/try-expand-list) -- cgit v1.2.3