Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

Add nrepl-op-supported-p.

  • Loading branch information...
commit 21245f4c64bf89c17ea805f4c74fca5b86b64ab5 1 parent 0c918c7
@kingtim kingtim authored
Showing with 6 additions and 1 deletion.
  1. +6 −1 nrepl.el
View
7 nrepl.el
@@ -1634,6 +1634,12 @@ restart the server."
(nrepl-jack-in current-prefix-arg))
;;; client
+(defun nrepl-op-supported-p (op)
+ "Return t iff the given operation is supported by nREPL server."
+ (with-current-buffer nrepl-connection-buffer
+ (if (and nrepl-ops (assoc op nrepl-ops))
+ t)))
+
(defun nrepl-describe-handler (process-buffer)
(lexical-let ((buffer process-buffer))
(lambda (response)
@@ -1653,7 +1659,6 @@ restart the server."
(switch-to-buffer-other-window buf)
buf)))
-
(defun nrepl-new-tooling-session-handler (process)
(lexical-let ((process process))
(lambda (response)
Please sign in to comment.
Something went wrong with that request. Please try again.