Skip to content

Commit 4f60783

Browse files
[debugger] Add P command to inspect the currently evaluted value
1 parent 420974b commit 4f60783

File tree

2 files changed

+5
-0
lines changed

2 files changed

+5
-0
lines changed

CHANGELOG.md

+1
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,7 @@
66

77
* [#605](https://github.com/clojure-emacs/cider-nrepl/pull/605): Added a option for filtering vars to the ns-vars middleware.
88
* Added `xref` middleware providing `fn-deps` and `fn-refs` ops.
9+
* [#613](https://github.com/clojure-emacs/cider-nrepl/pull/613): Add the ability to inspect current debugger value by pressing P.
910

1011
### Bugs fixed
1112

src/cider/nrepl/middleware/debug.clj

+4
Original file line numberDiff line numberDiff line change
@@ -305,6 +305,7 @@ this map (identified by a key), and will `dissoc` it afterwards."}
305305
"n" :next
306306
"o" :out
307307
"p" :inspect
308+
"P" :insPect
308309
"q" :quit
309310
"s" :stacktrace
310311
"t" :trace})
@@ -370,6 +371,9 @@ this map (identified by a key), and will `dissoc` it afterwards."}
370371
(assoc dbg-state :inspect)
371372
(recur value))
372373
(recur value dbg-state))
374+
:insPect (->> (debug-inspect page-size value)
375+
(assoc dbg-state :inspect)
376+
(recur value))
373377
:inject (try-if-let [val (read-eval-expression "Expression to inject: " dbg-state code)]
374378
val
375379
(recur value dbg-state))

0 commit comments

Comments
 (0)