This is the mail archive of the
gcc@gcc.gnu.org
mailing list for the GCC project.
Re: -Wcast-qual and casting away
- From: "Joseph S. Myers" <joseph at codesourcery dot com>
- To: Ian Lance Taylor <iant at google dot com>
- Cc: gcc at gcc dot gnu dot org
- Date: Thu, 21 May 2009 11:58:27 +0000 (UTC)
- Subject: Re: -Wcast-qual and casting away
- References: <m3r5yjxcpw.fsf@google.com>
On Wed, 20 May 2009, Ian Lance Taylor wrote:
> All that aside, I can't think of any reason that the C and C++ frontends
> should be different in this regard. Does anybody want to make an
There's the fairly obvious reason that C and C++ have different rules on
implicit conversions involving const, so const at higher levels of
indirection is irrelevant in C in a way that it is not in C++. (Adoption
of the C++ rules was considered and rejected for C99.)
--
Joseph S. Myers
joseph@codesourcery.com