[Top][All Lists]

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

Re: 23.1.50; gdb mode screwup when setting breakpoint

From: Dmitry Dzhus
Subject: Re: 23.1.50; gdb mode screwup when setting breakpoint
Date: Tue, 25 Aug 2009 00:12:13 +0400
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/23.1.50 (gnu/linux)

Miles Bader wrote:

> error in process filter: gdb-table-string: Symbol's function definition is 
> void: mapcar*

Yup, sorry about this. I've (finally) fixed this in trunk, so the code
doesn't use mapcar* anymore.

This function was utilized by small code which aligns text in columns.

I decided just to write a replacement for mapcar* which I think mimics
its notorious parent pretty closely, at least in my case.

Perhaps someone may have some comments about it:

    (defun gdb-mapcar* (function &rest seqs)
      "Apply FUNCTION to each element of SEQS, and make a list of the results.
    If there are several SEQS, FUNCTION is called with that many
    arugments, and mapping stops as sson as the shortest list runs
      (let ((shortest (apply #'min (mapcar #'length seqs))))
        (mapcar (lambda (i)
                  (apply function
                          (lambda (seq)
                            (nth i seq))
                (number-sequence 0 (1- shortest)))))

(docstring is just copied from cl's mapcar*).

I've grepped through other packages and discovered that there's a
gnus-mapcar macro (so big!) which seems to be a replacement for mapcar*
as well. I was thinking about defaliasing it and using for my code, but
fixme comment about gnus-mapcar in gnus-util.el says that

    ;; Fixme: This has only one use (in gnus-agent), which isn't worthwhile.

I'm not sure about its meaning, but probably it's safer to use a
homebrewn version in `gdb-mi.el`. Also having a debugger interface
depend on gnus-util package sounds weird.
Happy Hacking.


reply via email to

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