Skip to content

Commit

Permalink
Merge pull request #195 from jodonnell/eval-at-point
Browse files Browse the repository at this point in the history
add eval at point and bind it to E in shortkey mode
  • Loading branch information
rocky committed Dec 10, 2017
2 parents 59b2563 + 1180d9f commit df03ba5
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 0 deletions.
5 changes: 5 additions & 0 deletions realgud/common/cmds.el
Original file line number Diff line number Diff line change
Expand Up @@ -288,6 +288,11 @@ EVENT should be a mouse click on the left fringe or margin."
#'realgud:cmd-eval-region
#'realgud:cmd-eval)))

(defun realgud:cmd-eval-at-point()
"Eval symbol under point."
(interactive)
(realgud:cmd-run-command (thing-at-point 'symbol) "eval"))

(defun realgud:cmd-finish(&optional arg)
"Run until the completion of the current stack frame.
Expand Down
1 change: 1 addition & 0 deletions realgud/common/shortkey.el
Original file line number Diff line number Diff line change
Expand Up @@ -62,6 +62,7 @@
(define-key map "j" 'realgud:cmd-jump)
(define-key map "c" 'realgud:cmd-continue)
(define-key map "e" 'realgud:cmd-eval-dwim)
(define-key map "E" 'realgud:cmd-eval-at-point)
(define-key map "U" 'realgud:cmd-until)
(define-key map [mouse-2] 'realgud:tooltip-eval)
(define-key map [left-fringe mouse-1] #'realgud-cmds--mouse-add-remove-bp)
Expand Down

0 comments on commit df03ba5

Please sign in to comment.