public inbox for gcc-bugs@sourceware.org help / color / mirror / Atom feed
From: "fang at csl dot cornell dot edu" <gcc-bugzilla@gcc.gnu.org> To: gcc-bugs@gcc.gnu.org Subject: [Bug c++/24667] [4.0/4.1 Regression] -Wcast-qual fails to reject offending cast for a old style cast Date: Fri, 04 Nov 2005 17:56:00 -0000 [thread overview] Message-ID: <20051104175628.11610.qmail@sourceware.org> (raw) In-Reply-To: <bug-24667-3227@http.gcc.gnu.org/bugzilla/> ------- Comment #3 from fang at csl dot cornell dot edu 2005-11-04 17:56 ------- Am I correct in expecting that const_cast<...> should pass -Wcast-qual without warning? That's the way I use it (in the few and rare cases that demand it) and it's met my expectations thus far. I'm kind of surprised I haven't tripped this bug myself, but that's because I stopped using C-style casts long ago, enforced by -Wold-style-cast -Werror. Adding -Wold-style-cast does trip a warning about old casts with the posted code, but nothing further about discarding qualifiers (gcc4). -- http://gcc.gnu.org/bugzilla/show_bug.cgi?id=24667
next prev parent reply other threads:[~2005-11-04 17:56 UTC|newest] Thread overview: 8+ messages / expand[flat|nested] mbox.gz Atom feed top 2005-11-04 6:11 [Bug c++/24667] New: -Wcast-qual fails to reject offending cast fang at csl dot cornell dot edu 2005-11-04 7:47 ` [Bug c++/24667] " fang at csl dot cornell dot edu 2005-11-04 14:33 ` [Bug c++/24667] [4.0/4.1 Regression] -Wcast-qual fails to reject offending cast for a old style cast pinskia at gcc dot gnu dot org 2005-11-04 17:56 ` fang at csl dot cornell dot edu [this message] 2005-11-04 21:18 ` janis at gcc dot gnu dot org 2005-11-15 17:50 ` [Bug c++/24667] [4.0/4.1 Regression] -Wcast-qual fails to warn about " mmitchel at gcc dot gnu dot org 2005-11-15 17:52 ` mmitchel at gcc dot gnu dot org 2005-11-15 17:57 ` mmitchel at gcc dot gnu dot org
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=20051104175628.11610.qmail@sourceware.org \ --to=gcc-bugzilla@gcc.gnu.org \ --cc=gcc-bugs@gcc.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: linkBe sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions for how to clone and mirror all data and code used for this inbox; as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).