all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
From: Tino Calancha <tino.calancha@gmail.com>
To: 31697-done@debbugs.gnu.org
Subject: bug#31697: 27.0.50; Add new macro dolist-with-progress-reporter
Date: Sun, 17 Jun 2018 18:38:14 +0900	[thread overview]
Message-ID: <871sd5bvnd.fsf@calancha-pc.dy.bbexcite.jp> (raw)
In-Reply-To: <87vab03r8d.fsf@gmail.com> (Tino Calancha's message of "Sun, 03 Jun 2018 23:00:02 +0900")

Tino Calancha <tino.calancha@gmail.com> writes:

> Tino Calancha <tino.calancha@gmail.com> writes:
>
>> +  (declare (indent 2) (debug ((symbolp form &optional form) form body)))
>> +  (let ((prep (make-symbol "--dolist-progress-reporter--"))
>> +        (count (make-symbol "--dolist-count--")))
>> +    `(let ((,prep ,reporter-or-message)
>> +           (,count 0))
>> +       (when (stringp ,prep)
>> +         (setq ,prep (make-progress-reporter ,prep 0 (1- (length ,(cadr spec))))))
>> +       (dolist ,spec
>> +         ,@body
>> +         (progress-reporter-update ,prep (setq ,count (1+ ,count))))
>> +       (progress-reporter-done ,prep)
>> +       (or ,@(cdr (cdr spec)) nil))))
> As pointed out by Noam in Bug#31696, I am also evaluating twice here the
> form at (nth 1 SPEC).  I must add another variable.
> Updated patch.
Implemented into master branch as commit
'Add new macro dolist-with-progress-reporter'
(edb1f85a27817a3fac38bb85752671414819203b)





      reply	other threads:[~2018-06-17  9:38 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2018-06-03 13:16 bug#31697: 27.0.50; Add new macro dolist-with-progress-reporter Tino Calancha
2018-06-03 14:00 ` Tino Calancha
2018-06-17  9:38   ` Tino Calancha [this message]

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=871sd5bvnd.fsf@calancha-pc.dy.bbexcite.jp \
    --to=tino.calancha@gmail.com \
    --cc=31697-done@debbugs.gnu.org \
    /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.