all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
From: Dmitry Dzhus <dima@sphinx.net.ru>
To: emacs-devel@gnu.org
Cc: Nick Roberts <nickrob@snap.net.nz>, Miles Bader <miles@gnu.org>
Subject: Re: 23.1.50; gdb mode screwup when setting breakpoint
Date: Tue, 25 Aug 2009 00:12:13 +0400	[thread overview]
Message-ID: <874orxq8de.fsf@sphinx.net.ru> (raw)
In-Reply-To: buozl9pbuif.fsf@dhlpc061.dev.necel.com

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
    out."
      (let ((shortest (apply #'min (mapcar #'length seqs))))
        (mapcar (lambda (i)
                  (apply function
                         (mapcar
                          (lambda (seq)
                            (nth i seq))
                          seqs)))
                (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.

http://sphinx.net.ru

  reply	other threads:[~2009-08-24 20:12 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2009-08-20 11:31 23.1.50; gdb mode screwup when setting breakpoint Miles Bader
2009-08-20 12:18 ` Nick Roberts
2009-08-24  6:23   ` Miles Bader
2009-08-24 20:12     ` Dmitry Dzhus [this message]
2009-08-25  1:02       ` Miles Bader

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=874orxq8de.fsf@sphinx.net.ru \
    --to=dima@sphinx.net.ru \
    --cc=emacs-devel@gnu.org \
    --cc=miles@gnu.org \
    --cc=nickrob@snap.net.nz \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
Code repositories for project(s) associated with this external index

	https://git.savannah.gnu.org/cgit/emacs.git
	https://git.savannah.gnu.org/cgit/emacs/org-mode.git

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.