GNU bug report logs -
#31232
27.0.50; Obsolete argument RESULT in the macro `dotimes'
Previous Next
Reported by: Juri Linkov <juri <at> linkov.net>
Date: Sat, 21 Apr 2018 20:58:02 UTC
Severity: minor
Merged with 16206,
39919,
41287
Found in versions 24.3, 26.3, 28.0.50
Done: Lars Ingebrigtsen <larsi <at> gnus.org>
Bug is archived. No further changes may be made.
Full log
Message #5 received at submit <at> debbugs.gnu.org (full text, mbox):
If the arg RESULT of dotimes is not yet deprecated,
then to legitimize its usage it needs to be fixed.
At least, this patch tries to do this (maybe not in the best way):
diff --git a/lisp/subr.el b/lisp/subr.el
index 9cf7d59..aa2dc49 100644
--- a/lisp/subr.el
+++ b/lisp/subr.el
@@ -246,8 +246,8 @@ dotimes
,@body)
(setq ,counter (1+ ,counter)))
,@(if (cddr spec)
- ;; FIXME: This let often leads to "unused var" warnings.
- `((let ((,(car spec) ,counter)) ,@(cddr spec))))))
+ ;; No-op ,(car spec) is added to avoid "unused var" warnings.
+ `((let ((,(car spec) ,counter)) ,(car spec) ,@(cddr spec))))))
`(let ((,temp ,end)
(,(car spec) ,start))
(while (< ,(car spec) ,temp)
This bug report was last modified 4 years and 236 days ago.
Previous Next
GNU bug tracking system
Copyright (C) 1999 Darren O. Benham,
1997,2003 nCipher Corporation Ltd,
1994-97 Ian Jackson.