changeset 104213:8642d488076f

(gdb-gud-context-call): Does not need to be a macro. (gdb-registers-handler-custom): Do not fail when register names are unavailable.
author Dmitry Dzhus <dima@sphinx.net.ru>
date Sun, 09 Aug 2009 00:17:01 +0000
parents 28307c643e9f
children 0cec7dac5f50
files lisp/ChangeLog lisp/progmodes/gdb-mi.el
diffstat 2 files changed, 14 insertions(+), 6 deletions(-) [+]
line wrap: on
line diff
--- a/lisp/ChangeLog	Sat Aug 08 23:23:39 2009 +0000
+++ b/lisp/ChangeLog	Sun Aug 09 00:17:01 2009 +0000
@@ -1,3 +1,10 @@
+2009-08-09  Dmitry Dzhus  <dima@sphinx.net.ru>
+
+	* progmodes/gdb-mi.el (gdb-gud-context-call): Does not need to be
+	a macro.
+	(gdb-registers-handler-custom): Do not fail when register names
+	are unavailable.
+
 2009-08-08  Dmitry Dzhus  <dima@sphinx.net.ru>
 
 	* progmodes/gdb-mi.el (gdb-control-all-threads)
--- a/lisp/progmodes/gdb-mi.el	Sat Aug 08 23:23:39 2009 +0000
+++ b/lisp/progmodes/gdb-mi.el	Sun Aug 09 00:17:01 2009 +0000
@@ -566,11 +566,11 @@
     command))
 
 ;; TODO Document this. We use noarg when not in gud-def
-(defmacro gdb-gud-context-call (cmd1 &optional cmd2 noall noarg)
-  `(gud-call
-    (concat
-     (gdb-gud-context-command ,cmd1 ,noall)
-     ,cmd2) ,(when (not noarg) 'arg)))
+(defun gdb-gud-context-call (cmd1 &optional cmd2 noall noarg)
+  (gud-call
+   (concat
+    (gdb-gud-context-command cmd1 noall)
+    cmd2) (when (not noarg) 'arg)))
 
 ;;;###autoload
 (defun gdb (command-line)
@@ -3550,6 +3550,7 @@
              (value (gdb-get-field register 'value))
              (register-name (nth (string-to-number register-number) 
                                  gdb-register-names)))
+        (when register-name
         (gdb-table-add-row
          table
          (list
@@ -3559,7 +3560,7 @@
             value))
          `(mouse-face highlight
            help-echo "mouse-2: edit value"
-           gdb-register-name ,register-name))))
+           gdb-register-name ,register-name)))))
     (insert (gdb-table-string table " "))
     (setq mode-name
           (gdb-current-context-mode-name "Registers"))))