bug-gnu-emacs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

bug#20106: 25.0.50 pdb shuns init


From: Lars Ingebrigtsen
Subject: bug#20106: 25.0.50 pdb shuns init
Date: Fri, 02 Aug 2019 14:44:19 +0200
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/27.0.50 (gnu/linux)

Andreas Röhler <andreas.roehler@easy-emacs.de> writes:

> gud.el
>
> While gud-query-cmdline would accept the file-name to debug as argument
>
> (defun gud-query-cmdline (minor-mode &optional init)
>
> don't see how to hand it over from pdb
>
>  (defun pdb (command-line)
>   "[...]"
>   (interactive
>    (list (gud-query-cmdline 'pdb)))

(I'm going through old bug reports that unfortunately have not received
any responses yet.)

(defun pdb (command-line)
  "Run pdb on program FILE in buffer `*gud-FILE*'.
The directory containing FILE becomes the initial working directory
and source-file directory for your debugger."
  (interactive
   (list (gud-query-cmdline 'pdb)))

That's a confusing doc string.  I think it means to say that it'll
prompt for a pdb command line, and that command line will include a file
name?  Testing seems to say that that's the case, and I'll adjust the
doc string in Emacs 27.

But I'm not quite sure what you want to have done here.  Do you want to
pass a file name to `gud-query-cmdline'?  That's what INIT in that
function is used for, but I'm not sure that really makes much sense --
when used interactively, you're prompted for the entire command, and
when called noninteractively, you can just pass in whatever command you
want, including the file.

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





reply via email to

[Prev in Thread] Current Thread [Next in Thread]