GNU bug report logs - #6740
Spurious byte compiler warnings

Previous Next

Package: emacs;

Reported by: Alan Mackenzie <acm <at> muc.de>

Date: Tue, 27 Jul 2010 19:56:01 UTC

Severity: minor

Full log


View this message in rfc822 format

From: Stefan Kangas <stefan <at> marxist.se>
To: Stefan Monnier <monnier <at> iro.umontreal.ca>
Cc: Dan Nicolaescu <dann <at> gnu.org>, 6740 <at> debbugs.gnu.org, Alan Mackenzie <acm <at> muc.de>
Subject: bug#6740: Spurious byte compiler warnings
Date: Wed, 18 Nov 2020 20:25:56 -0800
Stefan Monnier <monnier <at> iro.umontreal.ca> writes:

>>> Warning: value returned from (featurep (quote cc-fix)) is unused
>>> Warning: value returned from (featurep (quote cc-fix)) is unused
>>>
>>> It is obvious that that value is indeed used.  This is a bug.
>
>> The byte compiler knows that (featurep 'xemacs) is false, so
>>  (and (not (featurep 'cc-fix)) ... )
>> will be false, so the featurep result is indeed unused.
>
>> If you use (and (featurep 'xemacs) (not (featurep 'cc-fix) ...
>> the warning will go away.
>
> It's one of those cases where the warning is the result of a check done
> "too late" (i.e. after some optimization), which means the check is not
> performed on the code the user sees, but on some massaged version of it.
> It's difficult to avoid them, short of removing all "code
> improvement" warnings.

(That was 10 years ago.)

I think this is a very minor issue that is likely not worth spending any
time on.  In any case, it's not even clear what the fix would be or if
a different behavior would improve the situation.

Does anyone object to closing this as wontfix?




This bug report was last modified 4 years and 203 days ago.

Previous Next


GNU bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson.