summaryrefslogtreecommitdiff
path: root/misc/rubydb3x.el
diff options
context:
space:
mode:
authormatz <matz@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>1999-07-15 07:59:59 +0000
committermatz <matz@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>1999-07-15 07:59:59 +0000
commit86307f52ee1b3c5aa76e2fd6ee118e681dd76905 (patch)
tree4f5675ce901200d4245c6697d4e8d1c224949174 /misc/rubydb3x.el
parente12510c502a3c8a81aeda66d1867eb1e760ce533 (diff)
990715
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_1_3@497 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'misc/rubydb3x.el')
-rw-r--r--misc/rubydb3x.el19
1 files changed, 13 insertions, 6 deletions
diff --git a/misc/rubydb3x.el b/misc/rubydb3x.el
index 197dd5327c..4493a93f77 100644
--- a/misc/rubydb3x.el
+++ b/misc/rubydb3x.el
@@ -7,8 +7,11 @@
;;; History of argument lists passed to rubydb.
(defvar gud-rubydb-history nil)
-(defun gud-rubydb-massage-args (file args)
- (cons "-r" (cons "debug" (cons file args))))
+(if (fboundp 'gud-overload-functions)
+ (defun gud-rubydb-massage-args (file args)
+ (cons "-r" (cons "debug" (cons file args))))
+ (defun gud-rubydb-massage-args (file args)
+ (cons "-r" (cons "debug" args))))
;; There's no guarantee that Emacs will hand the filter the entire
;; marker at once; it could be broken up across several strings. We
@@ -17,6 +20,7 @@
;; beginning of a marker, we save it here between calls to the
;; filter.
(defvar gud-rubydb-marker-acc "")
+(make-variable-buffer-local 'gud-rubydb-marker-acc)
(defun gud-rubydb-marker-filter (string)
(setq gud-rubydb-marker-acc (concat gud-rubydb-marker-acc string))
@@ -85,10 +89,13 @@ and source-file directory for your debugger."
nil nil
'(gud-rubydb-history . 1))))
- (gud-overload-functions '((gud-massage-args . gud-rubydb-massage-args)
- (gud-marker-filter . gud-rubydb-marker-filter)
- (gud-find-file . gud-rubydb-find-file)))
- (gud-common-init command-line rubydb-command-name)
+ (if (not (fboundp 'gud-overload-functions))
+ (gud-common-init command-line 'gud-rubydb-massage-args
+ 'gud-rubydb-marker-filter 'gud-rubydb-find-file)
+ (gud-overload-functions '((gud-massage-args . gud-rubydb-massage-args)
+ (gud-marker-filter . gud-rubydb-marker-filter)
+ (gud-find-file . gud-rubydb-find-file)))
+ (gud-common-init command-line rubydb-command-name))
(gud-def gud-break "b %l" "\C-b" "Set breakpoint at current line.")
; (gud-def gud-remove "clear %l" "\C-d" "Remove breakpoint at current line")