summaryrefslogtreecommitdiff
path: root/lisp
diff options
context:
space:
mode:
authorChong Yidong <cyd@gnu.org>2012-07-28 23:12:12 +0800
committerChong Yidong <cyd@gnu.org>2012-07-28 23:12:12 +0800
commit8c74a125c85da08e34dceedb271b71b5f09ce690 (patch)
tree338a380b3bb95e05923b6b76ae871161863ed84f /lisp
parent1eee634131dea9cf32d6ab83a06c0776b680fe8e (diff)
parenta55739d3d02606d60f511b1ce558dd503b69acba (diff)
downloademacs-8c74a125c85da08e34dceedb271b71b5f09ce690.tar.gz
Merge from emacs-24 branch; up to 2012-05-01T18:47:23Z!rgm@gnu.org
Diffstat (limited to 'lisp')
-rw-r--r--lisp/ChangeLog10
-rw-r--r--lisp/progmodes/cc-menus.el8
-rw-r--r--lisp/progmodes/gdb-mi.el29
3 files changed, 28 insertions, 19 deletions
diff --git a/lisp/ChangeLog b/lisp/ChangeLog
index f31218506ba..24477cf87ea 100644
--- a/lisp/ChangeLog
+++ b/lisp/ChangeLog
@@ -1,3 +1,13 @@
+2012-07-28 Chong Yidong <cyd@gnu.org>
+
+ * progmodes/gdb-mi.el (gdb-place-breakpoints): Fix the call to
+ gdb-get-location.
+
+2012-07-25 Leo Liu <sdl.web@gmail.com>
+
+ * progmodes/cc-menus.el (cc-imenu-objc-function): Avoid leaving nil in
+ the alist (bug#12029).
+
2012-07-28 Eli Zaretskii <eliz@gnu.org>
* makefile.w32-in (custom-deps, finder-data, updates, compile)
diff --git a/lisp/progmodes/cc-menus.el b/lisp/progmodes/cc-menus.el
index a53d65f6307..76e3002abd2 100644
--- a/lisp/progmodes/cc-menus.el
+++ b/lisp/progmodes/cc-menus.el
@@ -399,14 +399,10 @@ Example:
str2 "@protocol")))
(setq str (cc-imenu-objc-remove-white-space str))
(setq methodlist (cons (cons str2
- (match-beginning langnum))
+ (match-beginning langnum))
methodlist))
- (setq toplist (cons nil (cons (cons str
- methodlist) toplist))
+ (setq toplist (cons (cons str methodlist) toplist)
methodlist nil))))
- ;;
- (if (eq (car toplist) nil)
- (setq toplist (cdr toplist)))
;; In this buffer, there is only one or zero @{interface|implementation|protocol}.
(if (< classcount 2)
diff --git a/lisp/progmodes/gdb-mi.el b/lisp/progmodes/gdb-mi.el
index 23a34b85194..80afdc0bedf 100644
--- a/lisp/progmodes/gdb-mi.el
+++ b/lisp/progmodes/gdb-mi.el
@@ -2487,20 +2487,23 @@ HANDLER-NAME handler uses customization of CUSTOM-DEFUN. See
(let ((file (bindat-get-field breakpoint 'fullname))
(flag (bindat-get-field breakpoint 'enabled))
(bptno (bindat-get-field breakpoint 'number)))
- (unless (file-exists-p file)
+ (unless (and file (file-exists-p file))
(setq file (cdr (assoc bptno gdb-location-alist))))
- (if (and file
- (not (string-equal file "File not found")))
- (with-current-buffer
- (find-file-noselect file 'nowarn)
- (gdb-init-buffer)
- ;; Only want one breakpoint icon at each location.
- (gdb-put-breakpoint-icon (string-equal flag "y") bptno
- (string-to-number line)))
- (gdb-input (concat "list " file ":1") 'ignore)
- (gdb-input "-file-list-exec-source-file"
- `(lambda () (gdb-get-location
- ,bptno ,line ,flag)))))))))
+ (if (or (null file)
+ (string-equal file "File not found"))
+ ;; If the full filename is not recorded in the
+ ;; breakpoint structure or in `gdb-location-alist', use
+ ;; -file-list-exec-source-file to extract it.
+ (when (setq file (bindat-get-field breakpoint 'file))
+ (gdb-input (concat "list " file ":1") 'ignore)
+ (gdb-input "-file-list-exec-source-file"
+ `(lambda () (gdb-get-location
+ ,bptno ,line ,flag))))
+ (with-current-buffer (find-file-noselect file 'nowarn)
+ (gdb-init-buffer)
+ ;; Only want one breakpoint icon at each location.
+ (gdb-put-breakpoint-icon (string-equal flag "y") bptno
+ (string-to-number line)))))))))
(defvar gdb-source-file-regexp "fullname=\"\\(.*?\\)\"")