This is the mail archive of the
gcc-patches@gcc.gnu.org
mailing list for the GCC project.
Re: [PATCH] Do not warn about C++ compatibility of casts to incomplete type
- From: "Joseph S. Myers" <joseph at codesourcery dot com>
- To: Paolo Bonzini <bonzini at gnu dot org>
- Cc: gcc-patches at gcc dot gnu dot org, Ian Lance Taylor <iant at google dot com>
- Date: Fri, 5 Nov 2010 17:32:53 +0000 (UTC)
- Subject: Re: [PATCH] Do not warn about C++ compatibility of casts to incomplete type
- References: <1288367432-3422-1-git-send-email-bonzini@gnu.org>
On Fri, 29 Oct 2010, Paolo Bonzini wrote:
> While working on an unrelated patch I noticed a small imprecision
> in -Wc++-compat: casts to pointer to incomplete type are erroneously
> flagged as invalid in C++, if the occurrence of the incomplete type
> in the cast is also the first one in the translation unit.
>
> This patch fixes this imprecision. Adding a new bit means that
> not putting the entire spec.kind into struct c_declspecs is not
> cheaper anymore, so this patch does that as well.
>
> Bootstrapped/regtested x86_64-pc-linux-gnu, ok?
OK.
--
Joseph S. Myers
joseph@codesourcery.com