spacepaste

a/src/swank/commands/indent.clj
b/src/swank/commands/indent.clj
49 49 (when (or (= body-position 'defun)
50 50 (not (neg? body-position)))
51 51 (list (name (:name (meta var)))
52 '.
53 52 body-position)))))
54 53
55 54 (defn- get-cache-update-for-var
68 67 (remove nil? (map (partial get-cache-update-for-var find-in-cache) (vals (ns-interns ns))))))
69 68
70 69 (defn- update-indentation-delta
71 "Update the cache and return the changes in a (symbol '. indent) list.
70 "Update the cache and return the changes in a (symbol indent) list.
72 71 If FORCE is true then check all symbols, otherwise only check
73 72 symbols belonging to the buffer package"
74 73 ([cache-ref load-all-ns?]
a/src/swank/core.clj
b/src/swank/core.clj
243 243 (send-to-emacs `(:return ~(thread-name (current-thread))
244 244 (:ok ~result) ~id)))
245 245 ;; swank function not defined, abort
246 (send-to-emacs `(:return ~(thread-name (current-thread)) (:abort) ~id))))
246 (send-to-emacs `(:return ~(thread-name (current-thread)) (:abort ~(str (Exception. (str "unknow swank function " (first form))))) ~id))))
247 247 (catch Throwable t
248 248 ;; Thread/interrupted clears this thread's interrupted status; if
249 249 ;; Thread.stop was called on us it may be set and will cause an
255 255 (cond
256 256 (debug-quit-exception? t)
257 257 (do
258 (send-to-emacs `(:return ~(thread-name (current-thread)) (:abort) ~id))
258 (send-to-emacs `(:return ~(thread-name (current-thread)) (:abort ~(str (.getCause t))) ~id))
259 259 (if-not (zero? *sldb-level*)
260 260 (throw t)))
261 261
262 262 (debug-abort-exception? t)
263 263 (do
264 (send-to-emacs `(:return ~(thread-name (current-thread)) (:abort) ~id))
264 (send-to-emacs `(:return ~(thread-name (current-thread)) (:abort ~(str (.getCause t))) ~id))
265 265 (if-not (zero? *sldb-level*)
266 266 (throw debug-abort-exception)))
267 267
268 268 (debug-continue-exception? t)
269 269 (do
270 (send-to-emacs `(:return ~(thread-name (current-thread)) (:abort) ~id))
270 (send-to-emacs `(:return ~(thread-name (current-thread)) (:abort ~(str (.getCause t))) ~id))
271 271 (throw t))
272 272
273 273 (debugger-exception? t)
281 281 (if debug-swank-clojure t (or (.getCause t) t))
282 282 id)
283 283 ;; reply with abort
284 (finally (send-to-emacs `(:return ~(thread-name (current-thread)) (:abort) ~id)))))))))
284 (finally (send-to-emacs `(:return ~(thread-name (current-thread)) (:abort ~(str (.getCause t))) ~id)))))))))
285 285
286 286 (defn- add-active-thread [thread]
287 287 (dosync
a/src/swank/core.clj
b/src/swank/core.clj
8 8 (:require (swank.util.concurrent [mbox :as mb])))
9 9
10 10 ;; Protocol version
11 (defonce protocol-version (atom "20100404"))
11 (defonce protocol-version (atom "2011-10-19"))
12 12
13 13 ;; Emacs packages
14 14 (def #^{:dynamic true} *current-package*)