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

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

[debbugs-tracker] bug#31232: closed (27.0.50; Obsolete argument RESULT i


From: GNU bug Tracking System
Subject: [debbugs-tracker] bug#31232: closed (27.0.50; Obsolete argument RESULT in the macro `dotimes')
Date: Sat, 28 Apr 2018 20:22:02 +0000

Your message dated Sat, 28 Apr 2018 23:21:05 +0300
with message-id <address@hidden>
and subject line Re: bug#16206: 24.3; Incorrect unused variable byte-compiler 
warning in dotimes
has caused the debbugs.gnu.org bug report #16206,
regarding 27.0.50; Obsolete argument RESULT in the macro `dotimes'
to be marked as done.

(If you believe you have received this mail in error, please contact
address@hidden)


-- 
16206: http://debbugs.gnu.org/cgi/bugreport.cgi?bug=16206
GNU Bug Tracking System
Contact address@hidden with problems
--- Begin Message --- Subject: 27.0.50; Obsolete argument RESULT in the macro `dotimes' Date: Sat, 21 Apr 2018 23:53:44 +0300 User-agent: Gnus/5.13 (Gnus v5.13) Emacs/27.0.50 (x86_64-pc-linux-gnu)
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)



--- End Message ---
--- Begin Message --- Subject: Re: bug#16206: 24.3; Incorrect unused variable byte-compiler warning in dotimes Date: Sat, 28 Apr 2018 23:21:05 +0300 User-agent: Gnus/5.13 (Gnus v5.13) Emacs/27.0.50 (x86_64-pc-linux-gnu)
Version: 27.0.50

>> But without that addition the sentence makes no sense when
>> the documentation describes the RESULT argument and then
>> at the end says that "RESULT should not be used".
>
> "Its use is deprecated".

Done in f4eeb0f.


--- End Message ---

reply via email to

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