comparison lisp/progmodes/gdb-ui.el @ 68773:dc49655f57ae

Update copyright for 2006.
author Nick Roberts <nickrob@snap.net.nz>
date Fri, 10 Feb 2006 09:00:31 +0000
parents e444fe32e1b4
children 47f77ab239fc b98066f4aa10 4b3d39451150
comparison
equal deleted inserted replaced
68772:57d1d56ae004 68773:dc49655f57ae
2 2
3 ;; Author: Nick Roberts <nickrob@gnu.org> 3 ;; Author: Nick Roberts <nickrob@gnu.org>
4 ;; Maintainer: FSF 4 ;; Maintainer: FSF
5 ;; Keywords: unix, tools 5 ;; Keywords: unix, tools
6 6
7 ;; Copyright (C) 2002, 2003, 2004, 2005 Free Software Foundation, Inc. 7 ;; Copyright (C) 2002, 2003, 2004, 2005, 2006
8 ;; Free Software Foundation, Inc.
8 9
9 ;; This file is part of GNU Emacs. 10 ;; This file is part of GNU Emacs.
10 11
11 ;; GNU Emacs is free software; you can redistribute it and/or modify 12 ;; GNU Emacs is free software; you can redistribute it and/or modify
12 ;; it under the terms of the GNU General Public License as published by 13 ;; it under the terms of the GNU General Public License as published by
2966 (if (re-search-forward " source language \\(\\S-*\\)\." nil t) 2967 (if (re-search-forward " source language \\(\\S-*\\)\." nil t)
2967 (setq gdb-current-language (match-string 1))) 2968 (setq gdb-current-language (match-string 1)))
2968 (gdb-invalidate-assembler)) 2969 (gdb-invalidate-assembler))
2969 2970
2970 2971
2972 ;; For debugging Emacs only (assumes that usual stack buffer already exists).
2973 (defun gdb-xbacktrace ()
2974 "Generate a full lisp level backtrace with arguments."
2975 (interactive)
2976 (setq my-frames nil)
2977 (with-current-buffer (get-buffer-create "xbacktrace")
2978 (erase-buffer))
2979 (let (frame-number gdb-frame-number)
2980 (with-current-buffer (gdb-get-buffer 'gdb-stack-buffer)
2981 (save-excursion
2982 (goto-char (point-min))
2983 (while (search-forward "in Ffuncall " nil t)
2984 (goto-char (line-beginning-position))
2985 (looking-at "^#\\([0-9]+\\)")
2986 (push (match-string-no-properties 1) my-frames)
2987 (forward-line 1))))
2988 (dolist (frame my-frames)
2989 (gdb-enqueue-input (list (concat "server frame " frame "\n")
2990 'ignore))
2991 ; (gdb-enqueue-input (list "server ppargs\n" 'gdb-get-arguments))
2992 (gud-basic-call "server ppargs")
2993 )
2994 (gdb-enqueue-input (list (concat "server frame " frame-number "\n")
2995 'ignore))))
2996
2997 (defun gdb-get-arguments ()
2998 (with-current-buffer "xbacktrace"
2999 (insert-buffer-substring (gdb-get-buffer 'gdb-partial-output-buffer))))
3000
2971 ;; Code specific to GDB 6.4 3001 ;; Code specific to GDB 6.4
2972 (defconst gdb-source-file-regexp-1 "fullname=\"\\(.*?\\)\"") 3002 (defconst gdb-source-file-regexp-1 "fullname=\"\\(.*?\\)\"")
2973 3003
2974 (defun gdb-set-gud-minor-mode-existing-buffers-1 () 3004 (defun gdb-set-gud-minor-mode-existing-buffers-1 ()
2975 "Create list of source files for current GDB session." 3005 "Create list of source files for current GDB session."