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

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

[debbugs-tracker] bug#23758: closed (25.1.50; Bogus warning from -Wwrite


From: GNU bug Tracking System
Subject: [debbugs-tracker] bug#23758: closed (25.1.50; Bogus warning from -Wwrite-strings)
Date: Sun, 12 Jun 2016 21:46:01 +0000

Your message dated Sun, 12 Jun 2016 17:45:09 -0400
with message-id <address@hidden>
and subject line Re: bug#23758: 25.1.50; Bogus warning from -Wwrite-strings
has caused the debbugs.gnu.org bug report #23758,
regarding 25.1.50; Bogus warning from -Wwrite-strings
to be marked as done.

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


-- 
23758: http://debbugs.gnu.org/cgi/bugreport.cgi?bug=23758
GNU Bug Tracking System
Contact address@hidden with problems
--- Begin Message --- Subject: 25.1.50; Bogus warning from -Wwrite-strings Date: Sun, 12 Jun 2016 15:56:32 -0400 User-agent: Mozilla/5.0 (Windows NT 10.0; WOW64; rv:45.0) Gecko/20100101 Thunderbird/45.1.1
I'm getting an "assignment discards ‘const’ qualifier from pointer
target type" warning in the Cygwin-w32 build because of the following
code in w32fns.c:

char *type_CtrlAlt = NULL;
[...]
type_CtrlAlt = "bB";

This warning goes away if I remove -Wwrite-strings from the enabled compiler warnings. Is this a compiler bug, or is there really something wrong with the code above that should warrant a warning?


In GNU Emacs 25.1.50.11 (x86_64-unknown-cygwin)
 of 2016-06-12 built on moufang
Repository revision: eacdc9eb6c89346fb72535632a1c65f6483b639f
Windowing system distributor 'Microsoft Corp.', version 10.0.10586

Configured using:
 'configure 'CFLAGS=-g3 -O0' --with-w32'




--- End Message ---
--- Begin Message --- Subject: Re: bug#23758: 25.1.50; Bogus warning from -Wwrite-strings Date: Sun, 12 Jun 2016 17:45:09 -0400 User-agent: Mozilla/5.0 (Windows NT 10.0; WOW64; rv:45.0) Gecko/20100101 Thunderbird/45.1.1
On 6/12/2016 4:01 PM, Noam Postavsky wrote:
On Sun, Jun 12, 2016 at 3:56 PM, Ken Brown <address@hidden> wrote:
I'm getting an "assignment discards ‘const’ qualifier from pointer
target type" warning in the Cygwin-w32 build because of the following
code in w32fns.c:

char *type_CtrlAlt = NULL;
[...]
type_CtrlAlt = "bB";

This warning goes away if I remove -Wwrite-strings from the enabled compiler
warnings.  Is this a compiler bug, or is there really something wrong with
the code above that should warrant a warning?

I think the warning is correct, and the code shoud use const char *type_CtrlAlt

Thank you. I was confused by the wording of the warning, but now I understand the issue.

Closing.

Ken



--- End Message ---

reply via email to

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