summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
Diffstat (limited to 'app-emacs/slime/files/2.0_p20080731/inspect-presentations.patch')
-rw-r--r--app-emacs/slime/files/2.0_p20080731/inspect-presentations.patch40
1 files changed, 40 insertions, 0 deletions
diff --git a/app-emacs/slime/files/2.0_p20080731/inspect-presentations.patch b/app-emacs/slime/files/2.0_p20080731/inspect-presentations.patch
new file mode 100644
index 000000000000..2a1cfae16545
--- /dev/null
+++ b/app-emacs/slime/files/2.0_p20080731/inspect-presentations.patch
@@ -0,0 +1,40 @@
+diff -Naur slime.old/contrib/slime-presentations.el slime/contrib/slime-presentations.el
+--- slime.old/contrib/slime-presentations.el 2007-10-28 22:21:39.000000000 +0100
++++ slime/contrib/slime-presentations.el 2007-10-28 22:22:31.000000000 +0100
+@@ -44,6 +44,15 @@
+ (make-variable-buffer-local
+ (defvar slime-presentation-start-to-point (make-hash-table)))
+
++(setq slime-inspector-value-provider
++ (lambda ()
++ (multiple-value-bind (presentation start end)
++ (slime-presentation-around-point (point))
++ (when presentation
++ ;; Point is within a presentation, so don't prompt, just
++ ;; inspect the presented object; don't play DWIM.
++ (slime-presentation-expression presentation)))))
++
+ (defun slime-mark-presentation-start (id &optional target)
+ "Mark the beginning of a presentation with the given ID.
+ TARGET can be nil (regular process output) or :repl-result."
+diff -Naur slime.old/slime.el slime/slime.el
+--- slime.old/slime.el 2007-10-28 22:21:38.000000000 +0100
++++ slime/slime.el 2007-10-28 22:22:31.000000000 +0100
+@@ -7454,11 +7454,15 @@
+ (defvar slime-inspector-mark-stack '())
+ (defvar slime-saved-window-config)
+
++(defvar slime-inspector-value-provider nil)
++
+ (defun slime-inspect (string)
+ "Eval an expression and inspect the result."
+ (interactive
+- (list (slime-read-from-minibuffer "Inspect value (evaluated): "
+- (slime-sexp-at-point))))
++ (list (or (and slime-inspector-value-provider
++ (funcall slime-inspector-value-provider))
++ (slime-read-from-minibuffer "Inspect value (evaluated): "
++ (slime-sexp-at-point)))))
+ (slime-eval-async `(swank:init-inspector ,string) 'slime-open-inspector))
+
+ (define-derived-mode slime-inspector-mode fundamental-mode "Slime-Inspector"