branch: externals/realgud commit e47abfbede7cc49aa6939117dfae49d860849a3a Merge: 4babac3 f20f1e3 Author: R. Bernstein <ro...@users.noreply.github.com> Commit: GitHub <nore...@github.com>
Merge pull request #197 from jodonnell/eval-command change E to put the thing at point in the read string --- realgud/common/cmds.el | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) diff --git a/realgud/common/cmds.el b/realgud/common/cmds.el index 06a202f..9c7f88f 100644 --- a/realgud/common/cmds.el +++ b/realgud/common/cmds.el @@ -16,6 +16,7 @@ ;; along with this program. If not, see <http://www.gnu.org/licenses/>. (require 'load-relative) +(require 'thingatpt) (require-relative-list '("send" "core") "realgud-") (require-relative-list '("buffer/command") "realgud-buffer-") (require-relative-list '("buffer/source") "realgud-buffer-") @@ -291,7 +292,14 @@ EVENT should be a mouse click on the left fringe or margin." (defun realgud:cmd-eval-at-point() "Eval symbol under point." (interactive) - (realgud:cmd-run-command (thing-at-point 'symbol) "eval")) + + (beginning-of-thing 'symbol) + (set-mark-command 'nil) + (end-of-thing 'symbol) + + (realgud:cmd-run-command + (read-string "Eval: " (thing-at-point 'symbol)) + "eval")) (defun realgud:cmd-finish(&optional arg) "Run until the completion of the current stack frame.