GNU bug report logs - #1412
what-file-line, used when writing gdb script

Previous Next

Package: emacs;

Reported by: "richardeng" <richardeng <at> foxmail.com>

Date: Sun, 23 Nov 2008 16:35:04 UTC

Severity: wishlist

Tags: patch, wontfix

Found in version 23.0.60

Done: Lars Ingebrigtsen <larsi <at> gnus.org>

Bug is archived. No further changes may be made.

To add a comment to this bug, you must first unarchive it, by sending
a message to control AT debbugs.gnu.org, with unarchive 1412 in the body.
You can then email your comments to 1412 AT debbugs.gnu.org in the normal way.

Toggle the display of automated, internal messages from the tracker.

View this report as an mbox folder, status mbox, maintainer mbox


Report forwarded to bug-submit-list <at> lists.donarmstrong.com, Emacs Bugs <bug-gnu-emacs <at> gnu.org>:
bug#1412; Package emacs. Full text and rfc822 format available.

Acknowledgement sent to "richardeng" <richardeng <at> foxmail.com>:
New bug report received and forwarded. Copy sent to Emacs Bugs <bug-gnu-emacs <at> gnu.org>. Full text and rfc822 format available.

Message #5 received at submit <at> emacsbugs.donarmstrong.com (full text, mbox):

From: "richardeng" <richardeng <at> foxmail.com>
To: "bug-gnu-emacs" <bug-gnu-emacs <at> gnu.org>
Subject: what-file-line, used when writing gdb script
Date: Mon, 24 Nov 2008 00:27:59 +0800
Package: emacs
Version: 23.0.60
Severity: wishlist

When I write gdb script, I need to set many breakpoints. such as:
b xxx_file.c:xxx_line_number
 
With following, I can do it easier.
-----
(defcustom what-file-line-separator ":"
  "Define the separator between file name and line number"
  :type 'string
  :group 'editing)
 
(defcustom what-file-line-killp nil
  "Toggle on/off kill to yank ring"
  :type 'boolean
  :group 'editing)
 
;; Maybe this variable is useless, because user can copy what they want in mini-buffer                                  
(defcustom what-file-line-fullpath t
  "Toggle on/off file name fullpath"
  :type 'boolean
  :group 'editing)
 
(defun what-file-line ()
  "Print the current buffer's file name and line nubmer"
  (interactive)
  (let ((n (line-number-at-pos))
        (file (buffer-file-name))
        result)
    (setq result (concat file what-file-line-separator (number-to-string n)))
    (message "%s" result)
    (if what-file-line-killp
        (kill-new result))))
-----
Q:
1. I don't know in which group the customized variables should be put?
2. The 3rd customized variable needn't, agree?
3. If this functionality is usefull, I want to implement a GUI version(as same as gdb-mouse-set-clear-breakpoint). So when user click the left margin when non-gdb-mode, user can get the filename-line pair)
 
What's your comment?







Added tag(s) patch. Request was from Glenn Morris <rgm <at> gnu.org> to control <at> debbugs.gnu.org. (Sat, 23 Jan 2010 00:53:02 GMT) Full text and rfc822 format available.

Information forwarded to bug-gnu-emacs <at> gnu.org:
bug#1412; Package emacs. (Mon, 29 Feb 2016 04:25:01 GMT) Full text and rfc822 format available.

Message #10 received at 1412 <at> debbugs.gnu.org (full text, mbox):

From: Lars Ingebrigtsen <larsi <at> gnus.org>
To: "richardeng" <richardeng <at> foxmail.com>
Cc: 1412 <at> debbugs.gnu.org
Subject: Re: bug#1412: what-file-line, used when writing gdb script
Date: Mon, 29 Feb 2016 15:23:48 +1100
"richardeng" <richardeng <at> foxmail.com> writes:

> Package: emacs
> Version: 23.0.60
> Severity: wishlist
>
> When I write gdb script, I need to set many breakpoints. such as:
> b xxx_file.c:xxx_line_number
>
> With following, I can do it easier.
> -----
> (defcustom what-file-line-separator ":"
>   "Define the separator between file name and line number"
>   :type 'string
>   :group 'editing)
>
> (defcustom what-file-line-killp nil
>   "Toggle on/off kill to yank ring"
>   :type 'boolean
>   :group 'editing)
>
> ;; Maybe this variable is useless, because user can copy what they want in mini-buffer                                  
> (defcustom what-file-line-fullpath t
>   "Toggle on/off file name fullpath"
>   :type 'boolean
>   :group 'editing)
>
> (defun what-file-line ()
>   "Print the current buffer's file name and line nubmer"
>   (interactive)
>   (let ((n (line-number-at-pos))
>         (file (buffer-file-name))
>         result)
>     (setq result (concat file what-file-line-separator (number-to-string n)))
>     (message "%s" result)
>     (if what-file-line-killp
>         (kill-new result))))

Hm...  I don't think this sounds generally very useful (it's both kinda
too low level to be useful as a command, and too high level to be useful
as a function), so I'm closing this bug report.  Please reopen if
disagreeing.

-- 
(domestic pets only, the antidote for overdose, milk.)
   bloggy blog: http://lars.ingebrigtsen.no




Added tag(s) wontfix. Request was from Lars Ingebrigtsen <larsi <at> gnus.org> to control <at> debbugs.gnu.org. (Mon, 29 Feb 2016 04:25:02 GMT) Full text and rfc822 format available.

bug closed, send any further explanations to 1412 <at> debbugs.gnu.org and "richardeng" <richardeng <at> foxmail.com> Request was from Lars Ingebrigtsen <larsi <at> gnus.org> to control <at> debbugs.gnu.org. (Mon, 29 Feb 2016 04:25:02 GMT) Full text and rfc822 format available.

bug archived. Request was from Debbugs Internal Request <help-debbugs <at> gnu.org> to internal_control <at> debbugs.gnu.org. (Mon, 28 Mar 2016 11:24:03 GMT) Full text and rfc822 format available.

This bug report was last modified 9 years and 141 days ago.

Previous Next


GNU bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson.